Subject: Re: syslog_r (Re: CVS commit: src/lib/libc)
To: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
From: Elad Efrat <elad@NetBSD.org>
List: tech-userlevel
Date: 10/26/2006 07:30:59
YAMAMOTO Takashi wrote:
>> Module Name:	src
>> Committed By:	christos
>> Date:		Wed Oct 25 23:49:31 UTC 2006
>>
>> Modified Files:
>> 	src/lib/libc: shlib_version
>> 	src/lib/libc/gen: Makefile.inc syslog.3 syslog.c
>> 	src/lib/libc/include: namespace.h
>>
>> Log Message:
>> add _r functions for syslog from OpenBSD
> 
> - are you sure if it's signal-safe?
>   it seems to involve stdio and even locale stuffs...
> 
> - even if its current implementation is signal-safe,
>   i don't think it's a good idea to document syslog_r as signal-safe.

the OpenBSD implementation is documented to be signal-safe, but that
might be because functions it relies on were also made signal-safe, at
least there.

take a look at their signal(3):

http://www.openbsd.org/cgi-bin/man.cgi?query=signal&sektion=3

-e.

-- 
Elad Efrat