| OLD | NEW |
| 1 # Copyright 2008-2012 Free Software Foundation, Inc. | 1 # Copyright 2008-2013 Free Software Foundation, Inc. |
| 2 | 2 |
| 3 # This program is free software; you can redistribute it and/or modify | 3 # This program is free software; you can redistribute it and/or modify |
| 4 # it under the terms of the GNU General Public License as published by | 4 # it under the terms of the GNU General Public License as published by |
| 5 # the Free Software Foundation; either version 3 of the License, or | 5 # the Free Software Foundation; either version 3 of the License, or |
| 6 # (at your option) any later version. | 6 # (at your option) any later version. |
| 7 # | 7 # |
| 8 # This program is distributed in the hope that it will be useful, | 8 # This program is distributed in the hope that it will be useful, |
| 9 # but WITHOUT ANY WARRANTY; without even the implied warranty of | 9 # but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 11 # GNU General Public License for more details. | 11 # GNU General Public License for more details. |
| (...skipping 21 matching lines...) Expand all Loading... |
| 33 } | 33 } |
| 34 | 34 |
| 35 set bp_location [gdb_get_line_number "set breakpoint here" $hdrfile] | 35 set bp_location [gdb_get_line_number "set breakpoint here" $hdrfile] |
| 36 | 36 |
| 37 # Set a breakpoint with multiple locations. | 37 # Set a breakpoint with multiple locations. |
| 38 | 38 |
| 39 gdb_test "break $hdrfile:$bp_location" \ | 39 gdb_test "break $hdrfile:$bp_location" \ |
| 40 "Breakpoint.*at.*: $hdrfile:$bp_location. \\(2 locations\\).*" \ | 40 "Breakpoint.*at.*: $hdrfile:$bp_location. \\(2 locations\\).*" \ |
| 41 "set breakpoint" | 41 "set breakpoint" |
| 42 | 42 |
| 43 # Do "info break" now so we can easily compare it with the later "info break" |
| 44 # if problems arise. |
| 45 gdb_test "info break" \ |
| 46 "\[\r\n\]1\.1.* y .* at .*$hdrfile:$bp_location.*\[\r\n\]1\.2.* y .* at .*$h
drfile:$bp_location.*" |
| 47 |
| 43 gdb_run_cmd | 48 gdb_run_cmd |
| 44 gdb_expect { | 49 gdb_expect { |
| 45 -re "Breakpoint \[0-9\]+,.*foo \\(i=0\\).*$gdb_prompt $" { | 50 -re "Breakpoint \[0-9\]+,.*foo \\(i=0\\).*$gdb_prompt $" { |
| 46 pass "run to breakpoint" | 51 pass "run to breakpoint" |
| 47 } | 52 } |
| 48 -re "$gdb_prompt $" { | 53 -re "$gdb_prompt $" { |
| 49 fail "run to breakpoint" | 54 fail "run to breakpoint" |
| 50 } | 55 } |
| 51 timeout { | 56 timeout { |
| 52 fail "run to breakpoint (timeout)" | 57 fail "run to breakpoint (timeout)" |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 | 109 |
| 105 gdb_test "break $hdrfile:$bp_location" \ | 110 gdb_test "break $hdrfile:$bp_location" \ |
| 106 "Breakpoint.*at.*: $hdrfile:$bp_location. \\(2 locations\\).*" \ | 111 "Breakpoint.*at.*: $hdrfile:$bp_location. \\(2 locations\\).*" \ |
| 107 "set multi_line_foo breakpoint" | 112 "set multi_line_foo breakpoint" |
| 108 gdb_test "continue" \ | 113 gdb_test "continue" \ |
| 109 ".*Breakpoint.*multi_line_foo \\(i=0\\).*" \ | 114 ".*Breakpoint.*multi_line_foo \\(i=0\\).*" \ |
| 110 "run to multi_line_foo breakpoint 4 afn" | 115 "run to multi_line_foo breakpoint 4 afn" |
| 111 gdb_test "continue" \ | 116 gdb_test "continue" \ |
| 112 ".*Breakpoint.*multi_line_foo \\(i=1\\).*" \ | 117 ".*Breakpoint.*multi_line_foo \\(i=1\\).*" \ |
| 113 "run to multi_line_foo breakpoint 4 bfn" | 118 "run to multi_line_foo breakpoint 4 bfn" |
| OLD | NEW |