Matej =?utf-8?q?Košík?= <[email protected]>,
Matej =?utf-8?q?Košík?= <[email protected]>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/[email protected]>


================
@@ -491,18 +493,18 @@ bool GDBRemoteCommunicationClient::GetVContSupported(char 
flavor) {
     m_supports_vCont_S = eLazyBoolNo;
     if (SendPacketAndWaitForResponse("vCont?", response) ==
         PacketResult::Success) {
-      const char *response_cstr = response.GetStringRef().data();
-      if (::strstr(response_cstr, ";c"))
-        m_supports_vCont_c = eLazyBoolYes;
-
-      if (::strstr(response_cstr, ";C"))
-        m_supports_vCont_C = eLazyBoolYes;
-
-      if (::strstr(response_cstr, ";s"))
-        m_supports_vCont_s = eLazyBoolYes;
-
-      if (::strstr(response_cstr, ";S"))
-        m_supports_vCont_S = eLazyBoolYes;
+      llvm::SmallVector<llvm::StringRef> flavors;
+      response.GetStringRef().split(";").second.split(flavors, ';');
+      for (llvm::StringRef flavor : flavors) {
----------------
DavidSpickett wrote:

I've been out code golfed :) Thank's Jason.

https://github.com/llvm/llvm-project/pull/182287
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to