From c69aced833683b5256554330aa652f3dd7556d10 Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Wed, 26 Jun 2013 14:51:52 -0400 Subject: [PATCH] LP1204123 Set SIGCHLD handler to DEFAULT for children (perl) Remove the special SIGCHLD handler applied to the parent/listener process from spawned child processes (drones) by setting child handler to DEFAULT. Otherwise, if an OpenSRF drone process spawns a sub-process, the drone will execute the SIGCHLD handler meant for the Listener when the sub-process dies, wherein hijinks ensue. Signed-off-by: Bill Erickson Signed-off-by: Jason Stephenson --- src/perl/lib/OpenSRF/Server.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/perl/lib/OpenSRF/Server.pm b/src/perl/lib/OpenSRF/Server.pm index d8103b6..1257a9c 100644 --- a/src/perl/lib/OpenSRF/Server.pm +++ b/src/perl/lib/OpenSRF/Server.pm @@ -449,7 +449,7 @@ sub spawn_child { } else { # child process - $SIG{$_} = 'DEFAULT' for (qw/INT TERM QUIT HUP/); + $SIG{$_} = 'DEFAULT' for (qw/INT TERM QUIT HUP CHLD/); if($self->{stderr_log}) { -- 2.11.0