diff options
author | Bob Manson <manson@cygnus> | 1997-01-31 04:38:01 +0000 |
---|---|---|
committer | Bob Manson <manson@cygnus> | 1997-01-31 04:38:01 +0000 |
commit | 0e865b395050d2d644ab7b51b18d5254ad3c33dd (patch) | |
tree | ad40a3ced9b10ca45cfcfbc94a174981a7cba153 /gdb/testsuite/config | |
parent | ef87597cfa6716bdf2e9d5be4b3f4b876d97fa97 (diff) | |
download | gdb-0e865b395050d2d644ab7b51b18d5254ad3c33dd.zip gdb-0e865b395050d2d644ab7b51b18d5254ad3c33dd.tar.gz gdb-0e865b395050d2d644ab7b51b18d5254ad3c33dd.tar.bz2 |
Miscellaneous fixes for config/slite.exp.
Diffstat (limited to 'gdb/testsuite/config')
-rw-r--r-- | gdb/testsuite/config/slite.exp | 37 |
1 files changed, 20 insertions, 17 deletions
diff --git a/gdb/testsuite/config/slite.exp b/gdb/testsuite/config/slite.exp index 7109a2e..771a9e1 100644 --- a/gdb/testsuite/config/slite.exp +++ b/gdb/testsuite/config/slite.exp @@ -141,23 +141,26 @@ proc gdb_load { arg } { } if [target_info exists gdb_serial] { - send_gdb "target remote [target_info gdb_serial]\n" - set timeout 60 - verbose "Timeout is now $timeout seconds" 2 - expect { - -i $gdb_spawn_id -re ".*Kill it?.*y or n.*" { - send_gdb "y\n"; - exp_continue - } - -i $gdb_spawn_id -re ".*$prompt $" { - verbose "Set remote target to [target_info serial]" 2 - } - -i $gdb_spawn_id timeout { - perror "Couldn't set remote target." - set timeout 10 - verbose "Timeout is now $timeout seconds" 2 - return -1 - } + set serial [target_info gdb_serial]; + } else { + set serial [target_info serial]; + } + send_gdb "target remote $serial\n" + set timeout 60 + verbose "Timeout is now $timeout seconds" 2 + expect { + -i $gdb_spawn_id -re ".*Kill it?.*y or n.*" { + send_gdb "y\n"; + exp_continue + } + -i $gdb_spawn_id -re ".*$prompt $" { + verbose "Set remote target to [target_info serial]" 2 + } + -i $gdb_spawn_id timeout { + perror "Couldn't set remote target." + set timeout 10 + verbose "Timeout is now $timeout seconds" 2 + return -1 } } |