diff options
author | E. Choroba <choroba@matfyz.cz> | 2020-06-26 21:19:24 +0200 |
---|---|---|
committer | Karl Williamson <khw@cpan.org> | 2020-07-30 15:52:38 -0600 |
commit | b248789b64d6bd277c52bfe608ed3192023af1bd (patch) | |
tree | 32bcd8ae5a3d7b5fae54ab7988efdefd6316fbf9 /lib/perl5db.t | |
parent | 67b5e820b9462a832786fae47188b044c8fd42fb (diff) | |
download | perl-b248789b64d6bd277c52bfe608ed3192023af1bd.tar.gz |
After running an action in the debugger, turn it off
When running with "c", there was no problem, but when running with "n"
or "s", once the action was executed, it kept executing on the
following lines, which wasn't expected. Clearing $action here prevents
this unwanted behaviour.
Diffstat (limited to 'lib/perl5db.t')
-rw-r--r-- | lib/perl5db.t | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/lib/perl5db.t b/lib/perl5db.t index 421229a54a..913a301d98 100644 --- a/lib/perl5db.t +++ b/lib/perl5db.t @@ -2800,6 +2800,28 @@ SKIP: } { + # GitHub #17901 + my $wrapper = DebugWrap->new( + { + cmds => + [ + 'a 4 $s++', + ('s') x 5, + 'x $s', + 'q' + ], + prog => '../lib/perl5db/t/test-a-statement-3', + switches => [ '-d' ], + stderr => 0, + } + ); + $wrapper->contents_like( + qr/^0 +2$/m, + 'Test that the a command runs only on the given lines.', + ); +} + +{ # perl 5 RT #126735 regression bug. local $ENV{PERLDB_OPTS} = "NonStop=0 RemotePort=non-existent-host.tld:9001"; my $output = runperl( stdin => "q\n", stderr => 1, switches => [ '-d' ], prog => '../lib/perl5db/t/fact' ); |