On Tuesday 17 January 2012 01:38:57 Richard Braun wrote:
> On Mon, Jan 16, 2012 at 10:52:58PM -0500, Mike Frysinger wrote:
> > this leaves the other fields of sigaction uninitialized.  i think we need:
> >     if (command == 0)
> >             return 1;
> > 
> > +   memset(&sa, 0, sizeof(sa));
> >     sa.sa_handler = SIG_IGN;
> >     sigemptyset(&sa.sa_mask);
> > -   sa.sa_flags = 0;
> >     sigaction(SIGQUIT, &sa, &save_quit);
> >     sigaction(SIGINT, &sa, &save_int);
> >     sigaddset(&sa.sa_mask, SIGCHLD);
> 
> I didn't realize this. But then, do we need to call sigemptyset() ?

if we want to be tricky and rely on the semantics there, then we can do that.  
in this case, i'd comment out the sigemptyset() and mention that the memset 
took care of it for us.
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
uClibc mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/uclibc

Reply via email to