Only try to run the old handlers if they're actually functions. They 
may be IGNORE or DEFAULT (which imply do nothing, or do the normal thing. In 
either case, they're strings, not methods.

        Patch by fu. 

diffs (12 lines):

diff -r a7cc201be96d -r 75d1841dd16f cgi-bin/ljlib.pl
--- a/cgi-bin/ljlib.pl  Mon Nov 01 22:13:33 2010 +0800
+++ b/cgi-bin/ljlib.pl  Mon Nov 01 22:34:58 2010 +0800
@@ -232,7 +232,7 @@ if ($SIG{'HUP'}) {
 if ($SIG{'HUP'}) {
     my $oldsig = $SIG{'HUP'};
     $SIG{'HUP'} = sub {
-        &{$oldsig};
+        &{$oldsig} if ref $oldsig eq "CODE";
         LJ::clear_caches();
     };
 } else {
_______________________________________________
dw-changelog mailing list
[email protected]
http://lists.dwscoalition.org/mailman/listinfo/dw-changelog

Reply via email to