Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: f45de3a3d2a7e65c625a8463b7c625064f9c9b8f
      
https://github.com/WebKit/WebKit/commit/f45de3a3d2a7e65c625a8463b7c625064f9c9b8f
  Author: Yijia Huang <[email protected]>
  Date:   2026-04-21 (Tue, 21 Apr 2026)

  Changed paths:
    M Source/JavaScriptCore/wasm/debugger/WasmDebugServer.cpp

  Log Message:
  -----------
  [JSC][WASM][Debugger] Fix DebugServer::reset() deadlock on reconnect after   
detach
https://bugs.webkit.org/show_bug.cgi?id=312706
rdar://175100149

Reviewed by Mark Lam.

Close the client socket after m_executionHandler->reset() instead of
before. resumeImpl() inside reset() blocks on m_debuggerContinue waiting
for wasmDebuggerOnResumeCallback() to call handlePostResume(). That
callback gates on hasDebugger() == isSocketValid(m_clientSocket), so
closing the socket first made hasDebugger() return false, causing the
callback to take the "not connected" early-return path and never notify
m_debuggerContinue. This deadlocked the accept thread, preventing any
subsequent LLDB reconnection after a detach (D packet).

m_isDebuggerReady=false is sufficient to gate new VM traps from entering
the debugger path while resumeImpl() runs.

Canonical link: https://commits.webkit.org/311703@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to