From: Hui Zhu Date: Thu, 25 Apr 2013 01:26:36 +0000 (+0000) Subject: 2013-04-25 Hui Zhu X-Git-Tag: gdb_7_6-2013-04-26-release~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fdc69460ce548d9d25e53fd58db19ea237ec8dac;p=thirdparty%2Fbinutils-gdb.git 2013-04-25 Hui Zhu PR gdb/15293 * breakpoint.c (bpstat_what): Add BPSTAT_WHAT_SINGLE to bp_dprintf. 2013-04-25 Hui Zhu PR gdb/15293 * gdb.base/dprintf.exp: Add ignore command. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index c35799b124d..1c9c92671b6 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2013-04-25 Hui Zhu + + PR gdb/15293 + + * breakpoint.c (bpstat_what): Add BPSTAT_WHAT_SINGLE to bp_dprintf. + 2013-04-24 Hui Zhu PR gdb/15165 diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c index 4bcfea794dd..a589e3fc0a0 100644 --- a/gdb/breakpoint.c +++ b/gdb/breakpoint.c @@ -5534,7 +5534,10 @@ bpstat_what (bpstat bs_head) break; case bp_dprintf: - this_action = BPSTAT_WHAT_STOP_SILENT; + if (bs->stop) + this_action = BPSTAT_WHAT_STOP_SILENT; + else + this_action = BPSTAT_WHAT_SINGLE; break; default: diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 1af13e803b9..e3abb18cd3d 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2013-04-25 Hui Zhu + + PR gdb/15293 + + * gdb.base/dprintf.exp: Add ignore command. + 2013-04-24 Hui Zhu PR gdb/15165 diff --git a/gdb/testsuite/gdb.base/dprintf.exp b/gdb/testsuite/gdb.base/dprintf.exp index 2b00c241b62..430168bab0e 100644 --- a/gdb/testsuite/gdb.base/dprintf.exp +++ b/gdb/testsuite/gdb.base/dprintf.exp @@ -40,6 +40,8 @@ gdb_breakpoint "main" gdb_test "dprintf foo,\"At foo entry\\n\"" \ "Dprintf .*" +gdb_test "ignore \$bpnum 1" ".*Will ignore next crossing of breakpoint.*" + gdb_test "dprintf $dp_location1,\"arg=%d, g=%d\\n\", arg, g" \ "Dprintf .*" @@ -61,7 +63,7 @@ gdb_run_cmd gdb_test "" "Breakpoint" -gdb_test "continue" "At foo entry.*arg=1234, g=1234.*" "1st dprintf, gdb" +gdb_test "continue" "arg=1234, g=1234.*" "1st dprintf, gdb" gdb_test "continue" "At foo entry.*arg=1235, g=2222.*" "2nd dprintf, gdb"