aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/string/u_strerr.c
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2011-05-25 18:41:10 +0000
committerEric Blake <eblake@redhat.com>2011-05-25 18:41:10 +0000
commit4805b60ccfeee32a4ac3547e680c917f9e5c1d39 (patch)
tree7035ae20768510551b6abb65549b1e51acd18e09 /newlib/libc/string/u_strerr.c
parent6215837523703c2c0b58200341ae3861d8b7a28d (diff)
downloadnewlib-4805b60ccfeee32a4ac3547e680c917f9e5c1d39.zip
newlib-4805b60ccfeee32a4ac3547e680c917f9e5c1d39.tar.gz
newlib-4805b60ccfeee32a4ac3547e680c917f9e5c1d39.tar.bz2
strerror: allow user hook to comply with POSIX rules
* libc/string/strerror.c (strerror): Split body into... (_strerror_r): ...new reentrant function. * libc/string/u_strerr.c (_user_strerror): Update signature. * libc/include/stdio.h (_strerror_r): New prototype. * libc/posix/collate.c (__collate_err): Adjust callers. * libc/stdio/perror.c (_perror_r): Likewise. * libc/string/strerror_r.c (strerror_r): Likewise. * libc/string/xpg_strerror_r.c (__xpg_strerror_r): Likewise.
Diffstat (limited to 'newlib/libc/string/u_strerr.c')
-rw-r--r--newlib/libc/string/u_strerr.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/newlib/libc/string/u_strerr.c b/newlib/libc/string/u_strerr.c
index fa4605c..7d902fe 100644
--- a/newlib/libc/string/u_strerr.c
+++ b/newlib/libc/string/u_strerr.c
@@ -1,8 +1,10 @@
#include <_ansi.h>
char *
-_DEFUN(_user_strerror, (errnum),
- int errnum)
+_DEFUN(_user_strerror, (errnum, internal, errptr),
+ int errnum _AND
+ int internal _AND
+ int *errptr)
{
return 0;
}