Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Getting GDB error message in DSF-GDB

Hi,
 
using DSF-GDB, does anyone know of a good way to have access to the GDB error message when an MI command fails?
From what I see, we include the error message within a string that says:
 
Failed to execute MI command:
-trace-define-variable marc
Error message from debugger back end:
Name of trace variable should start with '$'
 
I just want the last line, so as to show it to the user in an error line.
 
In AbstractMIControl, this full string is passed back to the requestMonitor as a Status with
the full string as the Status message.
 
Of course I could parse this string, but that doesn't seem very elegant.
I don't want to change the format of the string because I don't want to do all
the regression tests that come with it.
 
My thought is to create an Exception and put the backend message in there,
and then to pass that Exception in the Status (since right now, no Exception is passed).
 
If anyone has a better idea, let me know.
 
Thanks
 
Marc
 
 

Back to the top