From owner-freebsd-standards@FreeBSD.ORG Wed Apr 11 19:00:14 2007 Return-Path: X-Original-To: freebsd-standards@hub.freebsd.org Delivered-To: freebsd-standards@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7B20C16A401 for ; Wed, 11 Apr 2007 19:00:14 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.freebsd.org (Postfix) with ESMTP id 719EA13C465 for ; Wed, 11 Apr 2007 19:00:14 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id l3BJ0E7x098580 for ; Wed, 11 Apr 2007 19:00:14 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id l3BJ0Eae098579; Wed, 11 Apr 2007 19:00:14 GMT (envelope-from gnats) Date: Wed, 11 Apr 2007 19:00:14 GMT Message-Id: <200704111900.l3BJ0Eae098579@freefall.freebsd.org> To: freebsd-standards@FreeBSD.org From: Jung-uk Kim Cc: Subject: Re: standards/80293: sysconf() does not support well-defined unistd values X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Jung-uk Kim List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Apr 2007 19:00:14 -0000 The following reply was made to PR standards/80293; it has been noted by GNATS. From: Jung-uk Kim To: bug-followup@FreeBSD.org, flashdict@gmail.com Cc: Subject: Re: standards/80293: sysconf() does not support well-defined unistd values Date: Wed, 11 Apr 2007 14:52:17 -0400 > We could probably return GRP_STORAGE_MAX as the limit value (1Mb > currently). Non-threaded versions of these functions is limited by > this value anyway. _SC_GETGR_R_SIZE_MAX is specifically for threaded versions and we should not use non-threaded version's limit. Interestingly, Mac OS 10.4 returns -1 without changing errno, which means it is unlimited. (FYI, Mac OS 10.3 used to return -1 with errno EINVAL.) NetBSD returns 1024 (which is arbitrary number chosen to shut up ports, I believe). SUSv3 says: 'If name is an invalid value, sysconf() shall return -1 and set errno to indicate the error. If the variable corresponding to name has no limit, sysconf() shall return -1 without changing the value of errno. Note that indefinite limits do not imply infinite limits; see .' Unfortunately FreeBSD falls under indefinite category and SUSv3 is not clear on this although it says indefinite does not imply infinite. :-( I am wondering how Mac OS 10.4 can claim that it is infinite. Jung-uk Kim