From owner-freebsd-hackers Thu Feb 26 18:31:17 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id SAA29609 for freebsd-hackers-outgoing; Thu, 26 Feb 1998 18:31:17 -0800 (PST) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from cimlogic.com.au (cimlog.lnk.telstra.net [139.130.51.31]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id SAA29600 for ; Thu, 26 Feb 1998 18:31:02 -0800 (PST) (envelope-from jb@cimlogic.com.au) Received: (from jb@localhost) by cimlogic.com.au (8.8.5/8.8.7) id NAA10868; Fri, 27 Feb 1998 13:32:09 +1100 (EST) (envelope-from jb) From: John Birrell Message-Id: <199802270232.NAA10868@cimlogic.com.au> Subject: Re: _POSIX_THREAD_SAFE_FUNCTIONS, but no thread-safe functions In-Reply-To: <34F65CCB.41C67EA6@opengroup.org> from "Kaleb S. KEITHLEY" at "Feb 27, 98 01:27:23 am" To: kaleb@opengroup.org Date: Fri, 27 Feb 1998 13:32:09 +1100 (EST) Cc: hackers@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL32 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Kaleb S. KEITHLEY wrote: > I'm looking at a 3.0-971225-SNAP machine, and has > _POSIX_THREAD_SAFE_FUNCTIONS defined, but libc_r does not have any of > the thread-safe functions, e.g. getpwnam_r, gethostbyname_r, strtok_r, > etc. The standard says that if _POSIX_THREADS is defined, then _POSIX_THREAD_SAFE_FUNCTIONS shall also be defined. [2.9.3] And then, for each function, it says "Either the implementation shall support the foobar() function as described above or the foobar() function shall not be provided". The standard doesn't prescribe how the feature test is supposed to be done. 8-( But we really should have these functions in libc. Generally, though, this involves a complete re-write of each of the existing functions in terms of the re-entrant versions. -- John Birrell - jb@cimlogic.com.au; jb@netbsd.org; jb@freebsd.org CIMlogic Pty Ltd, GPO Box 117A, Melbourne Vic 3001, Australia +61 418 353 137 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message