Skip to content

Conversation

@aarzilli
Copy link
Member

If a disconnect requests comes in while the runUntilStopAndNotify
goroutine is hitting a breakpoint a nil debugger dereference can happen
at various points.

This change resolves the problem by never resetting the debugger field
to nil, instead a separate flag is set (which mostly just exist to
avoid duplicate logging and to keep tests happy).

Fixes #4006, #4007, #4020

If a disconnect requests comes in while the runUntilStopAndNotify
goroutine is hitting a breakpoint a nil debugger dereference can happen
at various points.

This change resolves the problem by never resetting the debugger field
to nil, instead a separate flag is set (which mostly just exist to
avoid duplicate logging and to keep tests happy).

Fixes go-delve#4006, go-delve#4007, go-delve#4020
Copy link
Member

@derekparker derekparker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@derekparker derekparker merged commit 3c4e58b into go-delve:master Jun 11, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

service/dap: telemetry report: DAP calls StopReason on nil debugger

2 participants