This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
[perl #57016] debugger: o warn=0 die=0 ignored
authorTye McQueen <tye@metronet.com>
Wed, 16 Jul 2008 13:02:27 +0000 (06:02 -0700)
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>
Sun, 7 Sep 2008 21:46:18 +0000 (21:46 +0000)
From: "Tye McQueen" (via RT) <perlbug-followup@perl.org>
Message-ID: <rt-3.6.HEAD-9960-1216238547-448.57016-75-0@perl.org>

p4raw-id: //depot/perl@34312

lib/perl5db.pl

index 40d2361..d5d3c08 100644 (file)
@@ -7735,6 +7735,8 @@ sub warnLevel {
         }
         elsif ($prevwarn) {
             $SIG{__WARN__} = $prevwarn;
+        } else {
+            undef $SIG{__WARN__};
         }
     } ## end if (@_)
     $warnLevel;
@@ -7776,6 +7778,9 @@ sub dieLevel {
         elsif ($prevdie) {
             $SIG{__DIE__} = $prevdie;
             print $OUT "Default die handler restored.\n";
+        } else {
+            undef $SIG{__DIE__};
+            print $OUT "Die handler removed.\n";
         }
     } ## end if (@_)
     $dieLevel;