You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by je...@apache.org on 2016/07/17 16:00:54 UTC
thrift git commit: THRIFT-3848: Perl ForkingServer must ignore
SIGCHLD to avoid infinite loop Client: Perl Patch: Jim King
Repository: thrift
Updated Branches:
refs/heads/master 4300b72b2 -> b6983df86
THRIFT-3848: Perl ForkingServer must ignore SIGCHLD to avoid infinite loop
Client: Perl
Patch: Jim King <ji...@simplivity.com>
This closes #1040
Project: http://git-wip-us.apache.org/repos/asf/thrift/repo
Commit: http://git-wip-us.apache.org/repos/asf/thrift/commit/b6983df8
Tree: http://git-wip-us.apache.org/repos/asf/thrift/tree/b6983df8
Diff: http://git-wip-us.apache.org/repos/asf/thrift/diff/b6983df8
Branch: refs/heads/master
Commit: b6983df867208bb31e0de95bdfe124b0c51826ae
Parents: 4300b72
Author: Jim King <ji...@simplivity.com>
Authored: Wed Jul 6 21:50:23 2016 -0400
Committer: Jens Geyer <je...@apache.org>
Committed: Sun Jul 17 18:00:24 2016 +0200
----------------------------------------------------------------------
lib/perl/lib/Thrift/Server.pm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/thrift/blob/b6983df8/lib/perl/lib/Thrift/Server.pm
----------------------------------------------------------------------
diff --git a/lib/perl/lib/Thrift/Server.pm b/lib/perl/lib/Thrift/Server.pm
index 97e6620..ac1e17d 100644
--- a/lib/perl/lib/Thrift/Server.pm
+++ b/lib/perl/lib/Thrift/Server.pm
@@ -125,7 +125,6 @@ sub _handleException
}
}
-
#
# SimpleServer from the Server base class that handles one connection at a time
#
@@ -191,6 +190,9 @@ sub serve
{
my $self = shift;
+ # THRIFT-3848: without ignoring SIGCHLD, perl ForkingServer goes into a tight loop
+ $SIG{CHLD} = 'IGNORE';
+
$self->{serverTransport}->listen();
while (1)
{