Browse Source

Added stop reason to debug status

merge-requests/365/head
eidheim 10 years ago
parent
commit
5ca9b4bfe6
  1. 11
      src/debug.cc

11
src/debug.cc

@ -123,8 +123,15 @@ void Debug::start(const std::string &command, const boost::filesystem::path &pat
std::string event_desc=stream.GetData(); std::string event_desc=stream.GetData();
event_desc.pop_back(); event_desc.pop_back();
auto pos=event_desc.rfind(" = "); auto pos=event_desc.rfind(" = ");
if(status_callback && pos!=std::string::npos) if(status_callback && pos!=std::string::npos) {
status_callback(event_desc.substr(pos+3)); auto status=event_desc.substr(pos+3);
if(state==lldb::StateType::eStateStopped) {
char buffer[100];
auto n=process->GetSelectedThread().GetStopDescription(buffer, 100);
status+=" ("+std::string(buffer, n)+")";
}
status_callback(status);
}
if(state==lldb::StateType::eStateStopped) { if(state==lldb::StateType::eStateStopped) {
auto line_entry=process->GetSelectedThread().GetSelectedFrame().GetLineEntry(); auto line_entry=process->GetSelectedThread().GetSelectedFrame().GetLineEntry();

Loading…
Cancel
Save