]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Fix recent gdb_breakpoint regression.
authorDoug Evans <dje@google.com>
Mon, 15 Oct 2012 21:31:19 +0000 (21:31 +0000)
committerDoug Evans <dje@google.com>
Mon, 15 Oct 2012 21:31:19 +0000 (21:31 +0000)
* gdb.java/jmisc.exp: gdb_breakpoint for $function - remove curly
braces from the parameter.
* gdb.java/jprint.exp: Likewise.
* lib/gdb.exp (runto): Fix call to gdb_breakpoint.

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.java/jmisc.exp
gdb/testsuite/gdb.java/jprint.exp
gdb/testsuite/lib/gdb.exp

index 1c6156e9d6f7c0b5c4f74fa3e97ff1f03db2bc9e..422cebe3f5daa742a938d4bc03b89dfea26d2be5 100644 (file)
@@ -1,3 +1,15 @@
+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.
+
 2012-10-11  Doug Evans  <dje@google.com>
 
        PR breakpoints/14643.
index 72158613eadfaa762382d7af1eb36684ef6b90a4..4bd1800a589a323be2d4af2d370e2d3bc10423d9 100644 (file)
@@ -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 b2d5d310cc34c78b5def973ba55636ad9ace9c80..116a4bafd59afa8facb3fa8b73e6128a4d4b8bc5 100644 (file)
@@ -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 cd128ba2458f3e0addb419c483fbc2d85ea0bff5..df2d81839e2ef092f272c03b13ea8efc220c8de8 100644 (file)
@@ -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;
     }