Date: Thu, 17 Feb 2011 18:30:15 GMT From: Jeremy Huddleston <jeremyhu@apple.com> To: freebsd-standards@FreeBSD.org Subject: Re: standards/151316: lib/libc/string/strerror.c r1.9 breaks POSIX Message-ID: <201102171830.p1HIUFri030979@freefall.freebsd.org>
index | next in thread | raw e-mail
The following reply was made to PR standards/151316; it has been noted by GNATS.
From: Jeremy Huddleston <jeremyhu@apple.com>
To: Jilles Tjoelker <jilles@stack.nl>
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: standards/151316: lib/libc/string/strerror.c r1.9 breaks POSIX
Date: Thu, 17 Feb 2011 10:06:19 -0800
On Oct 9, 2010, at 05:37, Jilles Tjoelker wrote:
>> This introduces a regression in SUS conformance.
>
> Please explain why.
Well first and foremost because it causes the SUS conformance tests to fail:
/tset/PTHR.os/cfuncs/strerror_r/T.strerror_r 1 Failed
Test Description:
For UNIX03 and POSIX01 modes:
If the _POSIX_THREAD_SAFE_FUNCTIONS option is supported:
The strerror_r(errnum, strerrbuf, buflen) function shall map
the error number in errnum to a locale-dependent error message
string and shall return the string in the buffer pointed to by
strerrbuf, with length buflen, and return 0.
Test Information:
strerror_r unexpectedly failed
strerror_r unexpectedly failed
strerror_r unexpectedly failed
strerror_r unexpectedly failed
strerror_r unexpectedly failed
strerror_r unexpectedly failed
strerror_r unexpectedly failed
strerror_r unexpectedly failed
> In any case, this is of little practical effect since few programs check
> the value of errno set by strerror(). If the patch is accepted,
> sys_errlist[0] will probably be changed to "Unknown error: 0" so the
> only difference is errno set by strerror().
You should change it to "No error: 0" or "Success: 0"
home |
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201102171830.p1HIUFri030979>
