tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

strerror(0) POSIX compliance



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

POSIX extension to ISO C says:

[CX] [Option Start] If the value of errnum is a valid error number,
the message string shall indicate what error occurred; if the value of
errnum is zero, the message string shall either be an empty string or
indicate that no error occurred; otherwise, if these functions
complete successfully, the message string shall indicate that an
unknown error occurred. [Option End]

http://pubs.opengroup.org/onlinepubs/9699919799/functions/strerror.html

Currently we hardcode the following text:
        "Undefined error: 0",                   /*  0 - ENOERROR */

- -- src/lib/libc/compat/gen/compat_errlist.c

gnulib check for strerror(0) POSIX compliance and it prohibits
"ndefined" string.

http://git.savannah.gnu.org/gitweb/?p=gnulib.git;a=blob;f=tests/test-str
error.c#l63

Can we change this string to "No error" indicating that there is no
error? GNU returns "Success".
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJW89RJAAoJEEuzCOmwLnZscTIQAJCNWexsrCMHzE/YPEyUiS1u
bha04rAscQCID3eOsyCzzy5ThcQy2l5iAXk/sS1z6xWlC/cPkxmdsYRNUlWy6vTR
qMvGjqcfsrHxox7T7Ifn7r4+90HX16FpUmFhA1GkwyAsoENRrul+c42EeH92/MTa
fej+QthJSLXNWEbKg9KA3zns8qOAsywSlxDsmJNajJ6v4P/FLryus0k+I9ug23/i
4J7ZFC7tWirPKgDysngVtFjvVdI/oVXlXGnTCly6cPnJvmozRt5ht/+KqQUKMHKC
05rFijQH7koOCa2maa//jpbHLWNkswhGPgxWrnhJMmNnHise5hFOIDzFpLNL7gCz
P+FW8AWAQgSEaPQ7QuQEm5pBEh3Chj6RCDFlv1ZACTUmyQ8WLU+zNvuEaA0msTLJ
t4+WaFXUtjhXfKK85T8dlgAjx+mZdknAan4tzGiqHUJ3/R4fuuklpqOM/9nmCsw0
gBAN4+I+trG+h2tFwp/HWret6yfjYZJL4/9Z0UCYDt3lsZy+NwzR+M2mtOv0Ov37
O0R6hDnm0NKsKABua/FqUkEktwkSjTQaIm8uFPElcfeuw3kD1dXED5CY9j3P7+KD
ozwYSZWZj7u3zRMuTPuIsLgsQuZ8BjxF8iqjdJM/H9BCHr+5xr/tC6XaQCaVjvzl
NII3szqRI8jrKMVLljBe
=e2xi
-----END PGP SIGNATURE-----


Home | Main Index | Thread Index | Old Index