* gdb.gdb/selftest.exp (do_steps_and_nexts): Don't reference

uninitialized value of "description".
This commit is contained in:
Doug Evans 2014-04-15 16:11:32 -07:00
parent bfb1f6c316
commit 87fd9e6ed8
2 changed files with 12 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2014-04-15 Doug Evans <dje@google.com>
* gdb.gdb/selftest.exp (do_steps_and_nexts): Don't reference
uninitialized value of "description".
2014-04-15 Keith Seitz <keiths@redhat.com>
* gdb.mi/mi-simplerun.exp (test_breakpoints_creation_and_listing):

View File

@ -222,7 +222,13 @@ proc do_steps_and_nexts {} {
set command "next"
}
-re ".*$gdb_prompt $" {
fail "unknown source line after $description"
# If $description hasn't been set yet, it's likely the file
# has been edited but gdb hasn't been recompiled.
if [info exists description] {
fail "unknown source line (after $description)"
} else {
fail "unknown source line"
}
return
}
default {