https://github.com/charles-zablit updated 
https://github.com/llvm/llvm-project/pull/205772

>From 8b99fd2f1126b81ded504b43f08e2774db37aad6 Mon Sep 17 00:00:00 2001
From: Charles Zablit <[email protected]>
Date: Thu, 25 Jun 2026 11:45:24 +0100
Subject: [PATCH 1/2] [lldb][gdb-remote] Send QSetSTDIOWindowSize for a 0x0
 size

---
 .../Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp 
b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
index b5e0b8887f039..06a82eee621d3 100644
--- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
@@ -2039,7 +2039,7 @@ int GDBRemoteCommunicationClient::SetSTDERR(const 
FileSpec &file_spec) {
 
 int GDBRemoteCommunicationClient::SetSTDIOWindowSize(uint16_t cols,
                                                      uint16_t rows) {
-  if (cols == 0 || rows == 0)
+  if ((cols == 0) != (rows == 0))
     return -1;
   StreamString packet;
   packet.Printf("QSetSTDIOWindowSize:cols=%u;rows=%u",

>From 906704f0a9c516b9565a51bbe3f8d04306ef8bd5 Mon Sep 17 00:00:00 2001
From: Charles Zablit <[email protected]>
Date: Thu, 25 Jun 2026 18:07:39 +0100
Subject: [PATCH 2/2] fixup! [lldb][gdb-remote] Send QSetSTDIOWindowSize for a
 0x0 size

---
 .../Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp  | 1 +
 1 file changed, 1 insertion(+)

diff --git 
a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp 
b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
index 06a82eee621d3..698bf5f7049cf 100644
--- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
@@ -2039,6 +2039,7 @@ int GDBRemoteCommunicationClient::SetSTDERR(const 
FileSpec &file_spec) {
 
 int GDBRemoteCommunicationClient::SetSTDIOWindowSize(uint16_t cols,
                                                      uint16_t rows) {
+  // The size is only valid if both or none of the dimensions are zero.
   if ((cols == 0) != (rows == 0))
     return -1;
   StreamString packet;

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

Reply via email to