This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[commit] Fix gdb testsuite regressions in 7.5 branch


Hi.

fyi, I committed this to the 7.5 branch.

2012-10-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
	    Doug Evans  <dje@google.com>

	Fix recent gdb_breakpoint regression.
	* gdb.java/jmisc.exp: gdb_breakpoint for $function - remove curly
	braces from the parameter.
	* gdb.java/jprint.exp: Likewise.

2012-10-15  Doug Evans  <dje@google.com>

	* lib/gdb.exp (runto): Fix call to gdb_breakpoint.

Index: gdb.java/jmisc.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.java/jmisc.exp,v
retrieving revision 1.25
diff -u -p -r1.25 jmisc.exp
--- gdb.java/jmisc.exp	22 Jun 2012 16:44:15 -0000	1.25
+++ gdb.java/jmisc.exp	15 Oct 2012 20:52:18 -0000
@@ -43,8 +43,8 @@ if [set_lang_java] then {
     # signature.
     runto_main
     set function "${testfile}.main(java.lang.String\[\])"
-    gdb_breakpoint "$function" { allow-pending }
-    gdb_breakpoint "${function}void" { allow-pending }
+    gdb_breakpoint "$function" allow-pending
+    gdb_breakpoint "${function}void" allow-pending
     gdb_continue_to_breakpoint $function
 
     gdb_test_multiple "ptype jmisc" "ptype jmisc" {
Index: gdb.java/jprint.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.java/jprint.exp,v
retrieving revision 1.23
diff -u -p -r1.23 jprint.exp
--- gdb.java/jprint.exp	22 Jun 2012 16:44:15 -0000	1.23
+++ gdb.java/jprint.exp	15 Oct 2012 20:52:18 -0000
@@ -43,8 +43,8 @@ if [set_lang_java] then {
     # signature.
     runto_main
     set function "${testfile}.main(java.lang.String\[\])"
-    gdb_breakpoint "$function" { allow-pending }
-    gdb_breakpoint "${function}void" { allow-pending }
+    gdb_breakpoint "$function" allow-pending
+    gdb_breakpoint "${function}void" allow-pending
     gdb_continue_to_breakpoint $function
 
     gdb_test "p jvclass.addprint(4,5,6)" " = 15" "unambiguous static call"
Index: lib/gdb.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/lib/gdb.exp,v
retrieving revision 1.213.2.1
diff -u -p -r1.213.2.1 gdb.exp
--- lib/gdb.exp	11 Oct 2012 16:52:57 -0000	1.213.2.1
+++ lib/gdb.exp	15 Oct 2012 20:52:18 -0000
@@ -460,7 +460,10 @@ proc runto { function args } {
 
     # We need to use eval here to pass our varargs args to gdb_breakpoint
     # which is also a varargs function.
-    if ![eval gdb_breakpoint $function $args] {
+    # But we also have to be careful because $function may have multiple
+    # elements, and we don't want Tcl to move the remaining elements after
+    # the first to $args.  That is why $function is wrapped in {}.
+    if ![eval gdb_breakpoint {$function} $args] {
 	return 0;
     }
 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]