Apply commit e0e6958aa074a7714cd7c4aa779a1dfede3a03b1 from upstream.
authorbluhm <bluhm@openbsd.org>
Tue, 6 Jan 2015 11:42:37 +0000 (11:42 +0000)
committerbluhm <bluhm@openbsd.org>
Tue, 6 Jan 2015 11:42:37 +0000 (11:42 +0000)
commit666046da478bf52cf6fe923638cbbeb27f3ad85d
treeb0aa8a49424dad0d47c473e2c716c352fc31f664
parent9e85ff02a3e0929411058bcec3b3f4f6093948be
Apply commit e0e6958aa074a7714cd7c4aa779a1dfede3a03b1 from upstream.
- Avoid deadlock when activating signals.  Fixes bug 3048812.
  Based on patch by Nicholas Marriott.
The deadlock was ultimately fixed in a different way (by disabling
reinit - see event.c r1.25).  Add it now for consistency but without
the Windows compatibility code.  Convert the fnctl() calls to
SOCK_CLOEXEC | SOCK_NONBLOCK to simplify the code.
OK nicm@
lib/libevent/signal.c