Author: sas Date: Fri Aug 21 11:51:56 2015 New Revision: 245708 URL: http://llvm.org/viewvc/llvm-project?rev=245708&view=rev Log: Implement handling of `library:` keys in thread stop replies.
Summary: When a windows remote stops because of a DLL load/unload, the debug server sends a stop reply packet that contains a `library` key with any value (usually just `library:1`). This indicates to the debugger that a library has been loaded or unloaded and that the list of libraries should be refreshed (usually with `qXfer:libraries:read`). This change just triggers a call to `LoadModules()` which in turns will send a remote library read command when a stop reply that requests it is received. Reviewers: clayborg, zturner, tberghammer Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D12218 Modified: lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp Modified: lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp?rev=245708&r1=245707&r2=245708&view=diff ============================================================================== --- lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp (original) +++ lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp Fri Aug 21 11:51:56 2015 @@ -2523,6 +2523,10 @@ ProcessGDBRemote::SetThreadStopInfo (Str ostr.Printf("%" PRIu64 " %" PRIu32, wp_addr, wp_index); description = ostr.GetString().c_str(); } + else if (key.compare("library") == 0) + { + LoadModules(); + } else if (key.size() == 2 && ::isxdigit(key[0]) && ::isxdigit(key[1])) { uint32_t reg = StringConvert::ToUInt32 (key.c_str(), UINT32_MAX, 16); _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits