[Lldb-commits] [lldb] [lldb][Windows] add stdin support to lldb-server (PR #201638)
via lldb-commits
lldb-commits at lists.llvm.org
Fri Jun 5 13:09:47 PDT 2026
================
@@ -873,8 +877,18 @@ Status ProcessGDBRemote::DoLaunch(lldb_private::Module *exe_module,
SetPrivateState(SetThreadStopInfo(response));
if (!disable_stdio) {
- if (pty.GetPrimaryFileDescriptor() != PseudoTerminal::invalid_fd)
+ if (pty.GetPrimaryFileDescriptor() != PseudoTerminal::invalid_fd) {
SetSTDIOFileDescriptor(pty.ReleasePrimaryFileDescriptor());
+ }
+#ifdef _WIN32
+ else if (m_stdin_forward) {
+ // No client-side PTY FD on Windows.
+ std::lock_guard<std::mutex> guard(m_process_input_reader_mutex);
+ if (!m_process_input_reader)
+ m_process_input_reader =
+ std::make_shared<IOHandlerProcessSTDIOWindows>(this);
+ }
+#endif
----------------
Nerixyz wrote:
This would also run for GDB remote connections to non-Windows systems, right? For example, if you'd attach to a process running under WSL for example. But that shouldn't be a problem.
https://github.com/llvm/llvm-project/pull/201638
More information about the lldb-commits
mailing list