GDB/MI executing a python command

Simon Marchi simark@simark.ca
Thu May 23 16:18:00 GMT 2019


On 2019-05-23 11:54 a.m., Jan Vrany wrote:
> I dont think so. In my opinion it *should* produce correct MI output.  If there's an MI channel
> opened, whenever the inferior is run or stopped, there should be an MI event, no matter what. 
> 
> Imagine you have an MI frontend and you execute, from CLI, a custom python command than in turn
> does gdb.execute("stepi") - or worse, gdb.execute("cont"). Then inferior is running but MI frontend
> still thinks it is stopped, making those two out of sync. This would lead in all sort of problems
> like frontent would still show "stopped", when switching thread in UI would result an MI error when
> trying to obtain stacktrace (which hard to handle, since all you get is a *localized* error message). 
> And so on.

Yes, but that's what the *running notification is for.  I was talking about the ^running, which
is not a notification, but a reply to a command.  It is strange that the MI channel gets a reply
for a command it did not send.

Simon



More information about the Gdb mailing list