]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gdb/testsuite/ChangeLog
gdb.threads/thread-specific.exp: Fix uninitialized variable references
authorMaciej W. Rozycki <macro@codesourcery.com>
Fri, 21 Mar 2014 23:51:16 +0000 (23:51 +0000)
committerMaciej W. Rozycki <macro@codesourcery.com>
Fri, 21 Mar 2014 23:51:16 +0000 (23:51 +0000)
commitecebef6a9acbca2f98e1ed64b986d792c6933ec5
tree0d83cab3f2647b414ee2e712b66780132c0e1bb1
parentecdf850f8515140a3c15bc8ca55172276bcc914d
gdb.threads/thread-specific.exp: Fix uninitialized variable references

This fixes:

FAIL: gdb.threads/thread-specific.exp: continue to thread-specific breakpoint (timeout)
ERROR: tcl error sourcing .../gdb/testsuite/gdb.threads/thread-specific.exp.
ERROR: can't read "this_breakpoint": no such variable
    while executing
"gdb_test_multiple "info breakpoint $this_breakpoint" "info on bp" {
    -re ".*stop only in thread (\[0-9\]*).*$gdb_prompt $" {
        set this_thread $expe..."
    (file ".../gdb/testsuite/gdb.threads/thread-specific.exp" line 108)
    invoked from within
"source .../gdb/testsuite/gdb.threads/thread-specific.exp"
    ("uplevel" body line 1)
    invoked from within
"uplevel #0 source .../gdb/testsuite/gdb.threads/thread-specific.exp"
    invoked from within
"catch "uplevel #0 source $test_file_name""

and then:

FAIL: gdb.threads/thread-specific.exp: continue to thread-specific breakpoint (timeout)
UNTESTED: gdb.threads/thread-specific.exp: info on bp
ERROR: tcl error sourcing .../gdb/testsuite/gdb.threads/thread-specific.exp.
ERROR: can't read "this_thread": no such variable
    while executing
"gdb_test {print $_thread} ".* = $this_thread" "thread var at break""
    (file ".../gdb/testsuite/gdb.threads/thread-specific.exp" line 119)
    invoked from within
"source .../gdb/testsuite/gdb.threads/thread-specific.exp"
    ("uplevel" body line 1)
    invoked from within
"uplevel #0 source .../gdb/testsuite/gdb.threads/thread-specific.exp"
    invoked from within
"catch "uplevel #0 source $test_file_name""

Final results:

FAIL: gdb.threads/thread-specific.exp: continue to thread-specific breakpoint (timeout)
UNTESTED: gdb.threads/thread-specific.exp: info on bp
UNTESTED: gdb.threads/thread-specific.exp: thread var at break

Of course the first failure best wasn't there, but failing that the script
shouldn't crash.

* gdb.threads/thread-specific.exp: Handle the lack of usable
$this_breakpoint and $this_thread.
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.threads/thread-specific.exp