mirror of
https://github.com/go-delve/delve.git
synced 2025-08-06 21:46:57 +02:00
service/dap: do not try to stacktrace an unreadable goroutine (#4056)
onThreadRequest should not try to get the location of unreadable goroutines. Fixes #4054
This commit is contained in:
parent
03640f2c8d
commit
52a73b0ecf
@ -1883,6 +1883,9 @@ func (s *Session) onThreadsRequest(request *dap.ThreadsRequest) {
|
||||
} else {
|
||||
writeLabelsForKeys(s.args.ShowPprofLabels)
|
||||
}
|
||||
if g.Unreadable != nil {
|
||||
threads[i].Name = fmt.Sprintf("%s Unreadable goroutine: %v", selected, g.Unreadable)
|
||||
} else {
|
||||
// File name and line number are communicated via `stackTrace`
|
||||
// so no need to include them here.
|
||||
loc := g.UserCurrent()
|
||||
@ -1890,6 +1893,7 @@ func (s *Session) onThreadsRequest(request *dap.ThreadsRequest) {
|
||||
threads[i].Id = int(g.ID)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
response := &dap.ThreadsResponse{
|
||||
Response: *newResponse(request.Request),
|
||||
|
Loading…
Reference in New Issue
Block a user