+2014-05-20 Yao Qi <yao@codesourcery.com>
+
+ * lib/gdb.exp (default_gdb_init): Rename argument 'args' by
+ 'test_file_name'. Treat args as a string instead of a list.
+ (gdb_init): Rename argument 'args' by 'test_file_name'.
+
2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
* gdb.arch/powerpc-power.exp: New file.
return [gdb_test "continue" ".*Breakpoint $decimal, $function .*" "continue to $function"]
}
-proc default_gdb_init { args } {
+proc default_gdb_init { test_file_name } {
global gdb_wrapper_initialized
global gdb_wrapper_target
global gdb_test_file_name
global cleanfiles
+ global pf_prefix
set cleanfiles {}
gdb_clear_suppressed
- set gdb_test_file_name [file rootname [file tail [lindex $args 0]]]
+ set gdb_test_file_name [file rootname [file tail $test_file_name]]
# Make sure that the wrapper is rebuilt
# with the appropriate multilib option.
match_max [match_max -d]
# We want to add the name of the TCL testcase to the PASS/FAIL messages.
- if { [llength $args] > 0 } {
- global pf_prefix
+ set pf_prefix "[file tail [file dirname $test_file_name]]/[file tail $test_file_name]:"
- set file [lindex $args 0]
-
- set pf_prefix "[file tail [file dirname $file]]/[file tail $file]:"
- }
global gdb_prompt
if [target_info exists gdb_prompt] {
set gdb_prompt [target_info gdb_prompt]
# if the banned variables and procedures are already traced.
set banned_traced 0
-proc gdb_init { args } {
+proc gdb_init { test_file_name } {
# Reset the timeout value to the default. This way, any testcase
# that changes the timeout value without resetting it cannot affect
# the timeout used in subsequent testcases.
set gdbserver_reconnect_p 1
unset gdbserver_reconnect_p
- return [eval default_gdb_init $args]
+ return [default_gdb_init $test_file_name]
}
proc gdb_finish { } {