summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorPeter Scott <Peter@PSDT.com>2000-09-04 06:16:38 -0700
committerJarkko Hietaniemi <jhi@iki.fi>2000-09-07 22:18:30 +0000
commit20928eff080431b8f531d604674100ee3d2b91eb (patch)
tree002b400718c37bd595f3b867a0212060e20d4f4b /lib
parenteaa5a4a2c0c31e24b252e23ecfd04a2a6c3d80a8 (diff)
downloadperl-20928eff080431b8f531d604674100ee3d2b91eb.tar.gz
perl5db.pl [Was: Re: Debugger question]
Message-Id: <4.3.2.7.2.20000904130939.00adae90@mail2a.jpl.nasa.gov> p4raw-id: //depot/perl@7032
Diffstat (limited to 'lib')
-rw-r--r--lib/perl5db.pl11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/perl5db.pl b/lib/perl5db.pl
index 586cfd8fd5..5418b5710d 100644
--- a/lib/perl5db.pl
+++ b/lib/perl5db.pl
@@ -617,7 +617,7 @@ EOP
next CMD;
}
}
- $cmd =~ /^q$/ && ($exiting = 1) && exit $?;
+ $cmd =~ /^q$/ && ($fall_off_end = 1) && exit $?;
$cmd =~ /^h$/ && do {
print_help($help);
next CMD; };
@@ -1430,7 +1430,7 @@ EOP
$piped= "";
}
} # CMD:
- $exiting = 1 unless defined $cmd;
+ $fall_off_end = 1 unless defined $cmd; # Emulate `q' on EOF
foreach $evalarg (@$post) {
&eval;
}
@@ -2684,10 +2684,11 @@ sub end_report {
}
END {
- $finished = $inhibit_exit; # So that some keys may be disabled.
+ $finished = 1 if $inhibit_exit; # So that some keys may be disabled.
+ $fall_off_end = 1 unless $inhibit_exit;
# Do not stop in at_exit() and destructors on exit:
- $DB::single = !$exiting && !$runnonstop;
- DB::fake::at_exit() unless $exiting or $runnonstop;
+ $DB::single = !$fall_off_end && !$runnonstop;
+ DB::fake::at_exit() unless $fall_off_end or $runnonstop;
}
package DB::fake;