From: J.T. Conklin Date: Wed, 20 Jul 1994 17:29:02 +0000 (+0000) Subject: Changed pattern in gdb_run_cmd to match up to the first newline only. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=959fea03b51d7106fe2fa8362c9e74d4085927fb;p=binutils-gdb.git Changed pattern in gdb_run_cmd to match up to the first newline only. The old pattern used ".*$", which could, and did, swallow up output that we were attempting to match elsewhere. --- diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index 1747e1d32dd..f6764d02f49 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -123,7 +123,10 @@ proc gdb_run_cmd {} { exp_continue } - -re "Starting program: .*$" {} + # The following pattern matches up to to the first newline *only*. + # Using ``.*$'' could swallow up output that we attempt to match + # elsewhere. + -re "Starting program: \[^\n\]*" {} } }