X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2Fcluster.pl;h=995500ca934239b4ca18ec6ba580d9ef96f8e3c8;hb=dc016a0633cdb15d29b9a71fdec2c230fbad201b;hp=5aef00562c7c45c28442822a7223d431e898f369;hpb=f18a5bbaecbb46d84daa3cfa7968697fb87da742;p=spider.git diff --git a/perl/cluster.pl b/perl/cluster.pl index 5aef0056..995500ca 100755 --- a/perl/cluster.pl +++ b/perl/cluster.pl @@ -78,7 +78,7 @@ package main; @inqueue = (); # the main input queue, an array of hashes $systime = 0; # the time now (in seconds) -$version = "1.45"; # the version no of the software +$version = "1.47"; # the version no of the software $starttime = 0; # the starting time of the cluster $lockfn = "cluster.lock"; # lock file name @outstanding_connects = (); # list of outstanding connects @@ -316,7 +316,7 @@ STDOUT->autoflush(1); Log('cluster', "DXSpider V$version started"); # banner -dbg('err', "DXSpider DX Cluster Version $version", "Copyright (c) 1998-2000 Dirk Koopman G1TLH"); +dbg('err', "DXSpider DX Cluster Version $version", "Copyright (c) 1998-2001 Dirk Koopman G1TLH"); # load Prefixes dbg('err', "loading prefixes ..."); @@ -338,21 +338,23 @@ Msg->new_server("$clusteraddr", $clusterport, \&login); dbg('err', "load badwords: " . (BadWords::load or "Ok")); # prime some signals -$SIG{INT} = \&cease; -$SIG{TERM} = \&cease; -$SIG{HUP} = 'IGNORE'; -$SIG{CHLD} = sub { $zombies++ }; - -$SIG{PIPE} = sub { dbg('err', "Broken PIPE signal received"); }; -$SIG{IO} = sub { dbg('err', "SIGIO received"); }; -$SIG{WINCH} = $SIG{STOP} = $SIG{CONT} = 'IGNORE'; -$SIG{KILL} = 'DEFAULT'; # as if it matters.... - -# catch the rest with a hopeful message -for (keys %SIG) { - if (!$SIG{$_}) { -# dbg('chan', "Catching SIG $_"); - $SIG{$_} = sub { my $sig = shift; DXDebug::confess("Caught signal $sig"); }; +unless ($^O =~ /^MS/) { + $SIG{INT} = \&cease; + $SIG{TERM} = \&cease; + $SIG{HUP} = 'IGNORE'; + $SIG{CHLD} = sub { $zombies++ }; + + $SIG{PIPE} = sub { dbg('err', "Broken PIPE signal received"); }; + $SIG{IO} = sub { dbg('err', "SIGIO received"); }; + $SIG{WINCH} = $SIG{STOP} = $SIG{CONT} = 'IGNORE'; + $SIG{KILL} = 'DEFAULT'; # as if it matters.... + + # catch the rest with a hopeful message + for (keys %SIG) { + if (!$SIG{$_}) { + # dbg('chan', "Catching SIG $_"); + $SIG{$_} = sub { my $sig = shift; DXDebug::confess("Caught signal $sig"); }; + } } }