This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
FYI: fix PR 10684
- From: Tom Tromey <tromey at redhat dot com>
- To: GDB Development <gdb at sourceware dot org>
- Date: Wed, 23 Sep 2009 11:19:48 -0600
- Subject: FYI: fix PR 10684
- Reply-to: Tom Tromey <tromey at redhat dot com>
I am checking this in on the trunk and the 7.0 branch.
This patch comes from PR 10684. It is small enough not to require
paperwork.
This is an obvious fix to the continued-line logic.
Tom
2009-09-23 John Wright <john.wright@hp.com>
PR gdb/10684:
* event-top.c (command_line_handler): Terminate linebuffer before
xstrdup.
Index: event-top.c
===================================================================
RCS file: /cvs/src/src/gdb/event-top.c,v
retrieving revision 1.68
diff -u -c -r1.68 event-top.c
cvs diff: conflicting specifications of output style
*** event-top.c 23 May 2009 16:17:15 -0000 1.68
--- event-top.c 23 Sep 2009 17:13:26 -0000
***************
*** 622,627 ****
--- 622,628 ----
if (p > linebuffer && *(p - 1) == '\\')
{
+ *p = '\0';
p--; /* Put on top of '\'. */
readline_input_state.linebuffer = xstrdup (linebuffer);