about summary refs log tree commit diff
path: root/stdlib
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-10-10 20:48:08 +0000
committerUlrich Drepper <drepper@redhat.com>1999-10-10 20:48:08 +0000
commit64ad0de291ebb06a0bb0ed9c6dd8e4069c9e7794 (patch)
tree3e06ae51056faa7d3b6003769760d8b7e3bda923 /stdlib
parentbe9cd93a78a536ea078d4f2c6c75fe858d6845e3 (diff)
downloadglibc-64ad0de291ebb06a0bb0ed9c6dd8e4069c9e7794.tar.gz
glibc-64ad0de291ebb06a0bb0ed9c6dd8e4069c9e7794.tar.xz
glibc-64ad0de291ebb06a0bb0ed9c6dd8e4069c9e7794.zip
Update.
	* stdlib/xpg_basename.c (__xpg_basename): Don't return pointer to
	slash before the basename [PR libc/1383].

	* argp/argp.h: Fix typo in last patch.
Diffstat (limited to 'stdlib')
-rw-r--r--stdlib/xpg_basename.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/stdlib/xpg_basename.c b/stdlib/xpg_basename.c
index b789bc9a1a..0e36807165 100644
--- a/stdlib/xpg_basename.c
+++ b/stdlib/xpg_basename.c
@@ -1,5 +1,5 @@
 /* Return basename of given pathname according to the weird XPG specification.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
 
@@ -62,6 +62,9 @@ __xpg_basename (char *filename)
 		while (p[1] != '\0')
 		  ++p;
 	    }
+	  else
+	    /* Go to the first character of the name.  */
+	    ++p;
 	}
     }