19 lines
755 B
Diff
19 lines
755 B
Diff
|
http://sourceware.org/ml/gdb-patches/2011-01/msg00460.html
|
||
|
|
||
|
Index: gdb-7.2/gdb/linespec.c
|
||
|
===================================================================
|
||
|
--- gdb-7.2.orig/gdb/linespec.c 2011-02-03 22:59:46.000000000 +0100
|
||
|
+++ gdb-7.2/gdb/linespec.c 2011-02-03 23:03:28.000000000 +0100
|
||
|
@@ -1230,7 +1230,10 @@ decode_compound (char **argptr, int funf
|
||
|
{
|
||
|
char *end = skip_quoted (saved_arg);
|
||
|
memmove (saved_arg, saved_arg + 1, end - saved_arg);
|
||
|
- memmove (end - 2, end, strlen (saved_arg) + 1);
|
||
|
+ if (&end[-2] >= saved_arg && end[-2] == '\'')
|
||
|
+ memmove (end - 2, end, strlen (end) + 1);
|
||
|
+ else
|
||
|
+ memmove (end - 1, end, strlen (end) + 1);
|
||
|
}
|
||
|
|
||
|
/* First check for "global" namespace specification, of the form
|