[libvirt] PATCH: 2/5: Fix signal handler race condition
Jim Meyering
jim at meyering.net
Tue Aug 19 16:25:01 UTC 2008
"Daniel P. Berrange" <berrange at redhat.com> wrote:
> This is the same patch from yesterday to fix the signal handler race
> condition. We block signals before doing a fork(), and then in the child
> reset all signal handlers before finally unblocking all signals. The
> parent will restore its original signal mask after fork. I've fixed the
> incorrect return code check on pthread_sigmask() and iterate from 1
> instead of 0. I'll switch to pid_t later, since that'll involve changing
> all callers too.
>
> In the internal.h file I also #define pthread_sigmask to sigprocmask
> for scenarios where we don't have pthread - as per other usage. This
> exposed a bug in remote_protocol.c file where it was not including
> the config.h file, hence that change here too
This looks fine now.
ACK.
> qemud/remote_protocol.c | 1
> qemud/remote_protocol.h | 1
> qemud/remote_protocol.x | 1
> src/internal.h | 1
More information about the libvir-list
mailing list