This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: MI output command error
- From: Bob Rossi <bob at brasko dot net>
- To: GDB <gdb at sources dot redhat dot com>
- Date: Wed, 9 Mar 2005 18:22:39 -0500
- Subject: Re: MI output command error
- References: <20050309023957.GB10866@white>
On Tue, Mar 08, 2005 at 09:39:57PM -0500, Bob Rossi wrote:
> Hi,
>
> The doco for -break-watch has,
> (gdb)
> -break-watch x
> ^done,wpt={number="2",exp="x"}
> (gdb)
> -exec-continue
> ^running
> ^done,reason="watchpoint-trigger",wpt={number="2",exp="x"},
> value={old="-268439212",new="55"},
> frame={func="main",args=[],file="recursive2.c",line="5"}
> (gdb)
>
> However, when I run it with GDB from CVS, I get,
>
> (gdb)
> -break-watch argc
> ^done,wpt={number="2",exp="argc"}
> (gdb)
> -exec-continue
> ^running
> (gdb)
> *stopped,reason="watchpoint-scope",wpnum="2",thread-id="0",frame={addr="0x40039dc9",func="__libc_start_main",args=[],from="/lib/libc.so.6"}
> (gdb)
>
> The problem is, the -exec-continue command in CVS has an extra '(gdb)'
> in it after '^running'. I don't know if the doco or GDB is correct.
> I do know that I think GDB is conforming to the MI output command
> syntax, even though I think the documentation output looks more correct.
>
> Was the extra "(gdb)" added to make the output command match the syntax?
> Is this a bug in the doco or in GDB?
Sorry to respond to my own Email, but the more I thought about it, I
realized that what GDB was outputting was definatly a bug. The
documentation is also incorrect. So, something will have to change in
order to get this output correct.
There is no way 1 MI input command can result in more than one MI output
commands. The front end would probably send 1 command, after it got back
the first "(gdb)", and then send another command for the second time.
This would cause the front end's buffer to get out of sync with GDB.
I'll look into fixing this when I get more time. If anyone think's that
this is not a problem, please let me know why.
Thanks,
Bob Rossi