diff options
author | Daniel Jacobowitz <drow@false.org> | 2008-03-21 15:33:11 +0000 |
---|---|---|
committer | Daniel Jacobowitz <drow@false.org> | 2008-03-21 15:33:11 +0000 |
commit | 6214f497d3f1800171978839ef029f712369e2f9 (patch) | |
tree | af177c71d56a8b1a91799e3891ca8e7719631ce0 /gdb/symtab.c | |
parent | 6309237547d076d68daaf8f4d0cd55c5964e1411 (diff) | |
download | gdb-6214f497d3f1800171978839ef029f712369e2f9.zip gdb-6214f497d3f1800171978839ef029f712369e2f9.tar.gz gdb-6214f497d3f1800171978839ef029f712369e2f9.tar.bz2 |
2008-03-21 Chris Demetriou <cgd@google.com>
* symtab.c (rbreak_command): Quote symbol name before passing
it to break_command.
* gdb.base/break.exp (rbreak junk): New test for rbreak
"Junk at end of arguments" issue.
Diffstat (limited to 'gdb/symtab.c')
-rw-r--r-- | gdb/symtab.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/gdb/symtab.c b/gdb/symtab.c index 40e31dc..ddd2310 100644 --- a/gdb/symtab.c +++ b/gdb/symtab.c @@ -3345,7 +3345,13 @@ rbreak_command (char *regexp, int from_tty) } else { - break_command (SYMBOL_LINKAGE_NAME (p->msymbol), from_tty); + char *string = alloca (strlen (SYMBOL_LINKAGE_NAME (p->msymbol)) + + 3); + strcpy (string, "'"); + strcat (string, SYMBOL_LINKAGE_NAME (p->msymbol)); + strcat (string, "'"); + + break_command (string, from_tty); printf_filtered ("<function, no debug info> %s;\n", SYMBOL_PRINT_NAME (p->msymbol)); } |