]> sourceware.org Git - newlib-cygwin.git/commitdiff
* libc/string/strerror.c (_strerror_r): Report "Success" for 0.
authorEric Blake <eblake@redhat.com>
Wed, 25 May 2011 21:05:11 +0000 (21:05 +0000)
committerEric Blake <eblake@redhat.com>
Wed, 25 May 2011 21:05:11 +0000 (21:05 +0000)
newlib/ChangeLog
newlib/libc/string/strerror.c

index cf900e453ee118fda4a47572375f40c903400cd7..82ca1a2f74cfdbe13b109e392da4314017b19603 100644 (file)
@@ -1,3 +1,7 @@
+2011-05-25  Eric Blake  <eblake@redhat.com>
+
+       * libc/string/strerror.c (_strerror_r): Report "Success" for 0.
+
 2011-05-25  Eric Blake  <eblake@redhat.com>
 
        * libc/string/strerror.c (strerror): Split body into...
index fd6edd9e274db5b59d4b9cd5d859e8c6c47561f7..8852c36c742a1dbe95181f9ccb4411898ce63710 100644 (file)
@@ -33,6 +33,9 @@ This implementation of <<strerror>> prints out the following strings
 for each of the values defined in `<<errno.h>>':
 
 o+
+o 0
+Success
+
 o E2BIG
 Arg list too long
 
@@ -361,6 +364,9 @@ _DEFUN (_strerror_r, (ptr, errnum, internal, errptr),
 
   switch (errnum)
     {
+    case 0:
+      error = "Success";
+      break;
 /* go32 defines EPERM as EACCES */
 #if defined (EPERM) && (!defined (EACCES) || (EPERM != EACCES))
     case EPERM:
This page took 0.054398 seconds and 5 git commands to generate.