[PATCH] Remove sys_poll() (raceless signal handler)?

Jeremy Allison jra at samba.org
Thu Feb 16 16:29:36 MST 2012


On Thu, Feb 09, 2012 at 04:14:12PM +1100, Andrew Bartlett wrote:
> This patch comes out of some work I've been doing with callcatcher, to
> find dead code in Samba.  
> 
> It seems we do not need the sys_poll() wrapper, as something else
> (tevent presumably) handles the creation of the signal file descriptor.
> 
> Either that, or we have a problem with the 'race-less signal handler',
> as none of the signal handlers call the magic sys_select_signal()
> function. 
> 
> I'm still unclear why we call poll directly, particularly in
> smbd/process.c, hence why I post these patches for review, but more
> particularly for comment.

I'm pretty sure these are correct. We certainly don't use sys_select_signal()
anymore..

The direct call to poll() inside smbd/process.c is
a historical holdover from the port from select -> poll
done for 3.6.x.

I'm pretty sure we now no longer need this inside smbd,
but I'll do more investagating to be sure.

Cheers,

	Jeremy.


More information about the samba-technical mailing list