summaryrefslogtreecommitdiff
path: root/lib/perl5db.pl
diff options
context:
space:
mode:
authorIlya Zakharevich <ilya@math.berkeley.edu>1998-10-27 20:23:27 -0500
committerGurusamy Sarathy <gsar@cpan.org>1998-10-28 22:03:31 +0000
commit65c9c81d8dce4e55f5c8527bd4579b49e9272c23 (patch)
treec6813bf5b3bd0beacafbe4a6dd837f5c7ef3d0ca /lib/perl5db.pl
parentd0ecd44c5964f10ab34d28eea63e112aa8c61503 (diff)
downloadperl-65c9c81d8dce4e55f5c8527bd4579b49e9272c23.tar.gz
Minor debugger tweaks
Message-Id: <199810280623.BAA06968@monk.mps.ohio-state.edu> p4raw-id: //depot/perl@2118
Diffstat (limited to 'lib/perl5db.pl')
-rw-r--r--lib/perl5db.pl11
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/perl5db.pl b/lib/perl5db.pl
index 1e5724fb22..03f9d44d4e 100644
--- a/lib/perl5db.pl
+++ b/lib/perl5db.pl
@@ -235,7 +235,11 @@ $pretype = [] unless defined $pretype;
warnLevel($warnLevel);
dieLevel($dieLevel);
signalLevel($signalLevel);
-&pager(defined($ENV{PAGER}) ? $ENV{PAGER} : "|more") unless defined $pager;
+&pager((defined($ENV{PAGER})
+ ? $ENV{PAGER}
+ : ($^O eq 'os2'
+ ? 'cmd /c more'
+ : 'more'))) unless defined $pager;
&recallCommand("!") unless defined $prc;
&shellBang("!") unless defined $psh;
$maxtrace = 400 unless defined $maxtrace;
@@ -412,11 +416,11 @@ EOP
$was_signal = $signal;
$signal = 0;
if ($single || ($trace & 1) || $was_signal) {
- $term || &setterm;
if ($emacs) {
$position = "\032\032$filename:$line:0\n";
print $LINEINFO $position;
} elsif ($package eq 'DB::fake') {
+ $term || &setterm;
print_help(<<EOP);
Debugged program terminated. Use B<q> to quit or B<R> to restart,
use B<O> I<inhibit_exit> to avoid stopping after program termination,
@@ -640,8 +644,9 @@ EOP
$arrow .= 'b' if $stop;
$arrow .= 'a' if $action;
print $OUT "$i$arrow\t", $dbline[$i];
- last if $signal;
+ $i++, last if $signal;
}
+ print $OUT "\n" unless $dbline[$i-1] =~ /\n$/;
}
$start = $i; # remember in case they want more
$start = $max if $start > $max;