Problem setting a breakpoint at a location containing spaces (using MI)

Francois Chouinard fchouinard@gmail.com
Thu Feb 12 22:50:00 GMT 2009


Thanks a lot!


On Thu, Feb 12, 2009 at 5:42 PM, Tom Tromey <tromey@redhat.com> wrote:
>>>>>> "Francois" == Francois Chouinard <fchouinard@gmail.com> writes:
>
> Francois> I know this sounds supremely basic but, using MI, what would
> Francois> be the syntax to insert a breakpoint when specifying a
> Francois> location containing spaces?
>
> FWIW I tried this on the CLI and used:
>
> (gdb) b "a b.c":5
>
> Based on this, plus reading mi-parse.c:mi_parse_argv and
> mi-cmd-break.c:mi_cmd_break_insert, I tried:
>
> -break-insert "\"a b.c\":5"
> ^done,bkpt={number="1",type="breakpoint",disp="keep",enabled="y",addr="0x080483c5",func="main",file="a b.c",fullname="/tmp/a b.c",line="5",times="0"}
>
> So this seems to work :-)
>
> Francois> Is there a protocol limitation? I know it works well with
> Francois> CLI but I wonder what is the correct variant to make it work
> Francois> with MI.
>
> I think the oddity here is that there is MI quoting to deal with, but
> also quoting handled by the location parsing code.
>
> Tom
>



More information about the Gdb mailing list