Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Marc Khouzam <marc.khouzam@ericsson.com>
To: Simon Marchi <simon.marchi@ericsson.com>,
	"'gdb-patches@sourceware.org'"	<gdb-patches@sourceware.org>
Subject: RE: [PATCH] PR mi/15806: Fix quoting of async events
Date: Mon, 28 Apr 2014 18:36:00 -0000	[thread overview]
Message-ID: <E59706EF8DB1D147B15BECA3322E4BDC1C60E1CA@eusaamb103.ericsson.se> (raw)
In-Reply-To: <1398568091-21253-1-git-send-email-simon.marchi@ericsson.com>

> -----Original Message-----
> From: gdb-patches-owner@sourceware.org [mailto:gdb-patches-
> owner@sourceware.org] On Behalf Of Simon Marchi
> Sent: Saturday, April 26, 2014 11:08 PM
> To: gdb-patches@sourceware.org
> Cc: Simon Marchi
> Subject: [PATCH] PR mi/15806: Fix quoting of async events
> 
> The quoting in whatever goes in the event_channel of MI is little bit broken.
> 
> Link for the lazy:
>   https://sourceware.org/bugzilla/show_bug.cgi?id=15806
> 
> Here is an example of a =library-loaded event with an ill-named directory,
> /tmp/how"are\you (the problem is present with every directory on
> Windows since it uses backslashes as a path separator). The result will be the
> following:
> 
> =library-loaded,id="/tmp/how"are\\you/libexpat.so.1",...
> 
> The " between 'how' and 'are' should be escaped.
> 
> Another bad behavior is double escaping in =breakpoint-created, for
> example:
> 
> =breakpoint-
> created,bkpt={...,fullname="/tmp/how\\"are\\\\you/test.c",...}

Another impact of this bug is that a frontend cannot properly obtain
the string used in a dprintf that was created from the console.  If a 
user manually creates a dprintf, the frontend would use 
=breakpoint-created to show this new dprintf.  With this bug
it becomes problematic to extract the printf string to be used.

I am not familiar with the intricacies of MI output escaping but I can 
confirm that the patch proposed by Simon fixes the issue I am seeing
with Eclipse and dprintf.

I don't know if it is too late for the maintenance release, but in case 
it is not, let me add my vote to have it included in 7.7.1.

Thanks

Marc


  reply	other threads:[~2014-04-28 18:36 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-27  3:08 Simon Marchi
2014-04-28 18:36 ` Marc Khouzam [this message]
2014-05-12 17:56 ` Simon Marchi
2014-05-16 15:42 ` Tom Tromey
2014-05-16 17:58   ` Simon Marchi
2014-05-16 18:24     ` Tom Tromey
2014-05-16 19:57       ` Simon Marchi
2014-05-16 20:17         ` Tom Tromey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E59706EF8DB1D147B15BECA3322E4BDC1C60E1CA@eusaamb103.ericsson.se \
    --to=marc.khouzam@ericsson.com \
    --cc=gdb-patches@sourceware.org \
    --cc=simon.marchi@ericsson.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox