https://github.com/charles-zablit created https://github.com/llvm/llvm-project/pull/183539
Now that https://github.com/llvm/llvm-project/pull/183332 is merged, we can remove the temporary Sleep when closing the ConPTY which mitigates a race condition. >From 06ac6b18e527897d446e288e2295ab43530f9fab Mon Sep 17 00:00:00 2001 From: Charles Zablit <[email protected]> Date: Thu, 26 Feb 2026 14:49:35 +0000 Subject: [PATCH] [lldb][windows] remove sleep before closing ConPTY --- lldb/source/Host/windows/PseudoConsole.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lldb/source/Host/windows/PseudoConsole.cpp b/lldb/source/Host/windows/PseudoConsole.cpp index 03ebabc2d8f75..da4b1310ea17c 100644 --- a/lldb/source/Host/windows/PseudoConsole.cpp +++ b/lldb/source/Host/windows/PseudoConsole.cpp @@ -138,10 +138,6 @@ bool PseudoConsole::IsConnected() const { } void PseudoConsole::Close() { - Sleep(50); // FIXME: This mitigates a race condition when closing the - // PseudoConsole. It's possible that there is still data in the - // pipe when we try to close it. We should wait until the data has - // been consumed. SetStopping(true); std::unique_lock<std::mutex> guard(m_mutex); if (m_conpty_handle != INVALID_HANDLE_VALUE) _______________________________________________ lldb-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
