This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 1/1] Fix internal warning when "gdb -p xxx" (test)
- From: Pedro Alves <palves at redhat dot com>
- To: Hui Zhu <hui_zhu at mentor dot com>
- Cc: gdb-patches ml <gdb-patches at sourceware dot org>
- Date: Wed, 19 Mar 2014 10:28:53 +0000
- Subject: Re: [PATCH 1/1] Fix internal warning when "gdb -p xxx" (test)
- Authentication-results: sourceware.org; auth=none
- References: <53271C09 dot 5000709 at mentor dot com> <53271ED2 dot 6010707 at redhat dot com> <53272958 dot 1080605 at redhat dot com> <5327F7D0 dot 1050304 at mentor dot com> <53281C69 dot 7090703 at redhat dot com> <532916F6 dot 9000808 at mentor dot com>
On 03/19/2014 04:03 AM, Hui Zhu wrote:
> + eval "spawn $GDB $INTERNAL_GDBFLAGS $GDBFLAGS --pid=$testpid"
> + expect {
> + -re "Reading symbols from.*$gdb_prompt $" {
> + pass "starting with --pid=$testpid"
Don't add the $testpid to the PASS/FAIL line, as it'll change between
testsuite runs, making gdb.sum diffs harder.
> + }
> + timeout { fail "(timeout) starting with --pid=$testpid" }
Instead of repeating the text, write:
set test "starting with --pid"
expect {
-re "Reading symbols from.*$gdb_prompt $" {
pass "$test"
}
timeout {
fail "$test (timeout)"
}
}
Otherwise OK.
Thanks!
--
Pedro Alves