public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* signalfd() semantics after execve()
@ 2007-07-14  7:41 Michael Kerrisk
  2007-07-14 18:53 ` Davide Libenzi
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Kerrisk @ 2007-07-14  7:41 UTC (permalink / raw)
  To: Davide Libenzi; +Cc: linux-kernel

Davide, 

I'm working on the signalfd(2) man page, and I've come
acorss some puzzling behaviour...  

What are the intended semantics of a signalfd file descriptor
after an execve()?

As far as I can work out, after an execve() the file descriptor
is still available, but reads from it always return 0, even if:

a) there were signals pending before the execve().
   However, sigpending() shows the signal as pending,
   and the signal can be accepted using sigwaitinfo().

b) we generate a signal after the execve().
 
Is this intended behavior (the "orphaned sighand" condition
mentioned in the draft man page you sent me?)?  Is it a bug?

Cheers,

Michael

-- 
Michael Kerrisk
maintainer of Linux man pages Sections 2, 3, 4, 5, and 7 

Want to help with man page maintenance?  
Grab the latest tarball at
http://www.kernel.org/pub/linux/docs/manpages , 
read the HOWTOHELP file and grep the source 
files for 'FIXME'.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-07-15  9:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-14  7:41 signalfd() semantics after execve() Michael Kerrisk
2007-07-14 18:53 ` Davide Libenzi
2007-07-15  9:17   ` Michael Kerrisk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox