From owner-freebsd-standards@FreeBSD.ORG Fri Oct 8 16:30:07 2010 Return-Path: Delivered-To: freebsd-standards@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0BC741065670 for ; Fri, 8 Oct 2010 16:30:07 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id C50888FC18 for ; Fri, 8 Oct 2010 16:30:06 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o98GU6BP042686 for ; Fri, 8 Oct 2010 16:30:06 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o98GU6oB042682; Fri, 8 Oct 2010 16:30:06 GMT (envelope-from gnats) Resent-Date: Fri, 8 Oct 2010 16:30:06 GMT Resent-Message-Id: <201010081630.o98GU6oB042682@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-standards@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Jeremy Huddleston Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F1B67106564A for ; Fri, 8 Oct 2010 16:28:55 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id E305B8FC13 for ; Fri, 8 Oct 2010 16:28:55 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o98GStq3089803 for ; Fri, 8 Oct 2010 16:28:55 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id o98GStim089802; Fri, 8 Oct 2010 16:28:55 GMT (envelope-from nobody) Message-Id: <201010081628.o98GStim089802@www.freebsd.org> Date: Fri, 8 Oct 2010 16:28:55 GMT From: Jeremy Huddleston To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: standards/151316: lib/libc/string/strerror.c r1.9 breaks POSIX X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Oct 2010 16:30:07 -0000 >Number: 151316 >Category: standards >Synopsis: lib/libc/string/strerror.c r1.9 breaks POSIX >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-standards >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Oct 08 16:30:06 UTC 2010 >Closed-Date: >Last-Modified: >Originator: Jeremy Huddleston >Release: trunk >Organization: Apple Inc >Environment: NA >Description: r1.9 of strerror.c did the following (from the changeslog) strerror()'s semantics have changed slightly such that an argument of 0 is now considered invalid and errno is set to EINVAL. This introduces a regression in SUS conformance. >How-To-Repeat: >Fix: In strerror.c's strerror_r - if (errnum < 1 || errnum >= sys_nerr) { + if (errnum < 0 || errnum >= sys_nerr) { And here's a man page change: @@ -110,7 +118,7 @@ .Er EINVAL as a warning. Error numbers recognized by this implementation fall in -the range 0 < +the range 0 <= .Fa errnum < .Fa sys_nerr . >Release-Note: >Audit-Trail: >Unformatted: