================
@@ -5135,14 +5145,19 @@ void ProcessGDBRemote::AddRemoteRegisters(
// query the target of gdb-remote for extended target information returns
// true on success (got register definitions), false on failure (did not).
-bool ProcessGDBRemote::GetGDBServerRegisterInfo(ArchSpec &arch_to_use) {
- // Make sure LLDB has an XML parser it can use first
- if (!XMLDocument::XMLEnabled())
- return false;
-
- // check that we have extended feature read support
+llvm::Error ProcessGDBRemote::GetGDBServerRegisterInfo(ArchSpec &arch_to_use) {
+ // If the remote does not offer XML, does not matter if we would have been
+ // able to parse it.
if (!m_gdb_comm.GetQXferFeaturesReadSupported())
- return false;
+ return llvm::createStringError(
+ llvm::inconvertibleErrorCode(),
+ "The debug server does not support \"qXfer:features:read\"");
+
+ if (!XMLDocument::XMLEnabled())
+ return llvm::createStringError(
+ llvm::inconvertibleErrorCode(),
+ "The debug server supports \"qXfer:features:read\", but LLDB does not "
+ "have XML enabled (check LLLDB_ENABLE_LIBXML2)");
----------------
DavidSpickett wrote:
Done.
https://github.com/llvm/llvm-project/pull/170478
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits