diff options
author | Manuel Novoa III <mjn3@codepoet.org> | 2005-07-28 03:36:45 +0000 |
---|---|---|
committer | Manuel Novoa III <mjn3@codepoet.org> | 2005-07-28 03:36:45 +0000 |
commit | 4dd29ad13268a9dfec24e4be4ad6304a05bed709 (patch) | |
tree | 4a4f99f994be7d83063d5a710bc4920850dc8278 /libc/string | |
parent | 0f8a6ff0ed7c57c636b79d8a7a9a78da837d763a (diff) |
Fix string.h. Change our _susv3_strerror_r to __xpg_strerror_r for glibc
compatibility. Also change _glibc_strerror_r to __glibc_strerror_r for
consistency.
Diffstat (limited to 'libc/string')
-rw-r--r-- | libc/string/Makefile | 4 | ||||
-rw-r--r-- | libc/string/wstring.c | 16 |
2 files changed, 10 insertions, 10 deletions
diff --git a/libc/string/Makefile b/libc/string/Makefile index 111bf2fdb..6b516c1c5 100644 --- a/libc/string/Makefile +++ b/libc/string/Makefile @@ -39,8 +39,8 @@ MOBJ= basename.o bcopy.o bzero.o dirname.o ffs.o memccpy.o memchr.o memcmp.o \ stpncpy.o strcasecmp.o strcasestr.o strcat.o strchrnul.o strchr.o \ strcmp.o strcpy.o strcspn.o strdup.o strlen.o strncasecmp.o strncat.o \ strncmp.o strncpy.o strndup.o strnlen.o strpbrk.o strrchr.o strsep.o \ - strspn.o strstr.o strtok.o strtok_r.o strerror.o _susv3_strerror_r.o \ - _string_syserrmsgs.o _glibc_strerror_r.o \ + strspn.o strstr.o strtok.o strtok_r.o strerror.o __xpg_strerror_r.o \ + _string_syserrmsgs.o __glibc_strerror_r.o \ _string_syssigmsgs.o sys_siglist.o strsignal.o psignal.o \ __xpg_basename.o strlcat.o strlcpy.o sys_errlist.o memmem.o diff --git a/libc/string/wstring.c b/libc/string/wstring.c index ed9ebb232..6f54ae615 100644 --- a/libc/string/wstring.c +++ b/libc/string/wstring.c @@ -1299,7 +1299,7 @@ char *strerror(int errnum) { static char buf[_STRERROR_BUFSIZE]; - _susv3_strerror_r(errnum, buf, sizeof(buf)); + __xpg_strerror_r(errnum, buf, sizeof(buf)); return buf; } @@ -1308,7 +1308,7 @@ char *strerror(int errnum) /**********************************************************************/ /* SUSv3 functions. */ /**********************************************************************/ -#ifdef L__susv3_strerror_r +#ifdef L___xpg_strerror_r #ifdef __UCLIBC_HAS_ERRNO_MESSAGES__ #if defined(__alpha__) || defined(__mips__) || defined(__sparc__) @@ -1450,7 +1450,7 @@ static const unsigned char estridx[] = { #endif -int _susv3_strerror_r(int errnum, char *strerrbuf, size_t buflen) +int __xpg_strerror_r(int errnum, char *strerrbuf, size_t buflen) { register char *s; int i, retval; @@ -1528,7 +1528,7 @@ int _susv3_strerror_r(int errnum, char *strerrbuf, size_t buflen) #else /* __UCLIBC_HAS_ERRNO_MESSAGES__ */ -int _susv3_strerror_r(int errnum, char *strerrbuf, size_t buflen) +int __xpg_strerror_r(int errnum, char *strerrbuf, size_t buflen) { register char *s; int i, retval; @@ -1569,13 +1569,13 @@ int _susv3_strerror_r(int errnum, char *strerrbuf, size_t buflen) /**********************************************************************/ /* GNU extension functions. */ /**********************************************************************/ -#ifdef L__glibc_strerror_r +#ifdef L___glibc_strerror_r -weak_alias(_glibc_strerror_r,__strerror_r); +weak_alias(__glibc_strerror_r,__strerror_r); -char *_glibc_strerror_r(int errnum, char *strerrbuf, size_t buflen) +char *__glibc_strerror_r(int errnum, char *strerrbuf, size_t buflen) { - _susv3_strerror_r(errnum, strerrbuf, buflen); + __xpg_strerror_r(errnum, strerrbuf, buflen); return strerrbuf; } |