diff --git a/ChangeLog b/ChangeLog index 9d81e2d109..7a5307fef1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue May 3 05:35:54 2016 Eric Wong + + * process.c (disable_child_handler_fork_child): + initialize handler for SIGPIPE for !POSIX_SIGNAL + Mon May 2 23:03:42 2016 NAKAMURA Usaku * win32/win32.c, include/ruby/win32.h (rb_w32_utruncate): implements new diff --git a/process.c b/process.c index 660c2c7314..6f3fc235f2 100644 --- a/process.c +++ b/process.c @@ -3502,8 +3502,12 @@ disable_child_handler_fork_child(struct child_handler_disabler_state *old, char for (sig = 1; sig < NSIG; sig++) { int reset = 0; #ifdef SIGPIPE - if (sig == SIGPIPE) + if (sig == SIGPIPE) { reset = 1; +#ifndef POSIX_SIGNAL + handler = SIG_DFL; +#endif + } #endif if (!reset) { #ifdef POSIX_SIGNAL