diff options
author | Yao Qi <yao@codesourcery.com> | 2014-05-20 13:45:54 +0800 |
---|---|---|
committer | Yao Qi <yao@codesourcery.com> | 2014-05-26 09:11:15 +0800 |
commit | 498a44896d5420739d7485fd52336b87410a0680 (patch) | |
tree | eaf8a99b0d8bf8b70c80825bb800ab18232a2c59 /gdb | |
parent | d77454b1a49157957434eb668f8a80fa7f8ebb30 (diff) | |
download | gdb-498a44896d5420739d7485fd52336b87410a0680.zip gdb-498a44896d5420739d7485fd52336b87410a0680.tar.gz gdb-498a44896d5420739d7485fd52336b87410a0680.tar.bz2 |
Specify source file explicitly when setting a breakpoint
When I run no-thread-db.exp, the breakpoint is set on line 26.
However, the breakpoint is set to line 26 of dl-start.S rather than
no-thread-db.c, which is not intended.
(gdb) monitor set libthread-db-search-path /foo/bar^M
libthread-db-search-path set to `/foo/bar'^M
(gdb) PASS: gdb.server/no-thread-db.exp: libthread-db is now unresolvable
break 26^M
Breakpoint 1 at 0x48018078: file ../sysdeps/powerpc/powerpc32/dl-start.S, line 26.^M
(gdb) continue^M
Continuing.
This patch is to change the breakpoint setting with source file
specified, then it is correct now.
gdb/testsuite:
2014-05-26 Yao Qi <yao@codesourcery.com>
* gdb.server/no-thread-db.exp: Specify source file name
explicitly when setting a breakpoint.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/testsuite/gdb.server/no-thread-db.exp | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 11f49ea..de32b61 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2014-05-26 Yao Qi <yao@codesourcery.com> + + * gdb.server/no-thread-db.exp: Specify source file name + explicitly when setting a breakpoint. + 2014-05-23 Markus Metzger <markus.t.metzger@intel.com> * gdb.btrace/vdso.c: New. diff --git a/gdb/testsuite/gdb.server/no-thread-db.exp b/gdb/testsuite/gdb.server/no-thread-db.exp index 9246fa9..8a9c291 100644 --- a/gdb/testsuite/gdb.server/no-thread-db.exp +++ b/gdb/testsuite/gdb.server/no-thread-db.exp @@ -47,7 +47,7 @@ gdb_test "monitor set libthread-db-search-path ${unresolvable_thread_db_path}" \ "libthread-db is now unresolvable" # Continue past tls assignment to make sure tls storage is allocated. -gdb_breakpoint [gdb_get_line_number "after tls assignment"] +gdb_breakpoint ${srcfile}:[gdb_get_line_number "after tls assignment"] gdb_continue_to_breakpoint "after tls assignment" # Printing a tls variable should fail gracefully without a libthread_db. |