One last time (Re: SIGCHLD race *trivial* patch)

Carson Gaspar carson at taltos.org
Tue Oct 30 10:10:19 EST 2001



--On Monday, October 29, 2001 11:04 PM +0100 Markus Friedl 
<markus at openbsd.org> wrote:

> On Mon, Oct 29, 2001 at 05:01:37PM -0500, Carson Gaspar wrote:
>> Use the POSIX signal functions, and _only_ the POSIX signal functions.
>> Nothing else is portable, and they all have rather nasty race
>> conditions.  The POSIX signal functions can trivially go back into the
>> OpenBSD main  source.
>
> so, and what are we using now?

I was originally responding to a message that claimed sigvec() was being 
used. It isn't. OpenSSH currently uses a terrible mix of signal() and 
sigaction(). Under Solaris, signal() has SYSV semantics, which is almost 
certainly not what you want. It looks like the source code just needs to 
have signal() replaced with mysignal(), which is defined in terms of 
sigaction in misc.c.

Sadly, the current CVS doesn't have configure.in, so 2.52 autoconf won't 
touch it. I can't check to see if weird macro re-writing of signal() is 
going on.

--
Carson






More information about the openssh-unix-dev mailing list