delve/pkg/proc
Alex Brainman 0cfe539052 proc/native: make sure debugged executable can be deleted on windows (#890)
* proc/native: make sure debugged executable can be deleted on windows

Delve opens debugged executable to read binary info it
contains, but it never closes the file. Windows will not
let you delete file that is opened. So close Process.bi
in Process.postExit, and actually call Process.postExit
from windows Process.Kill.

Also Windows sends some debugging events
(EXIT_PROCESS_DEBUG_EVENT event in particular) after Delve
calls TerminateProcess. The events need to be consumed by
debugger before debugged process will be released by
Windows. So call Process.waitForDebugEvent after
TerminateProcess in Process.Kill.

Fixes #398

* cmd/dlv: make TestIssue398 pass on darwin

* cmd/dlv: add comment for TestIssue398

* proc/native: wait for debuggee to exit before returning from windows Process.Kill

* proc/native: close process handle before returning from windows killProcess

* proc/native: remove not used Process.Process
2017-07-26 12:51:44 -06:00
..
core proc/core: support floating point registers (#912) 2017-07-20 13:04:00 -06:00
gdbserial proc/native,proc/gdbserial: set selectedGoroutine after StepInstruction 2017-07-26 12:50:09 -06:00
native proc/native: make sure debugged executable can be deleted on windows (#890) 2017-07-26 12:51:44 -06:00
test proc/gdbserial: mozilla rr support (#804) 2017-05-05 15:17:52 -07:00
arch.go proc: read G struct offset from runtime.tlsg if possible (#883) 2017-06-21 15:40:42 -07:00
bininfo.go proc/eval: optimize variable lookup (#925) 2017-07-18 12:55:24 -06:00
breakpoints.go proc: next, stepout should work on recursive goroutines (#831) 2017-05-16 11:23:33 -07:00
disasm_amd64.go Fix various issues detected by megacheck (#880) 2017-06-29 11:15:59 -07:00
disasm.go proc: refactoring: merge target into proc 2017-04-21 14:00:04 -07:00
doc.go Move top-level packages into pkg 2017-02-08 12:17:19 -08:00
eval.go proc/eval: fix interface equality with nil (#914) 2017-07-07 11:08:36 -07:00
go_version.go Fix various issues detected by megacheck (#880) 2017-06-29 11:15:59 -07:00
interface.go proc: fix interaction of RequestManualStop and conditional breakpoints (#876) 2017-07-07 16:29:37 -07:00
mem.go proc: refactoring: split backends to separate packages 2017-04-21 14:00:04 -07:00
moduledata.go proc: next, stepout should work on recursive goroutines (#831) 2017-05-16 11:23:33 -07:00
proc_general_test.go proc: refactoring: split backends to separate packages 2017-04-21 14:00:04 -07:00
proc_test.go proc: fix next when current function is unknown on macOS 2017-07-26 12:50:09 -06:00
proc_unix_test.go Fix various issues detected by megacheck (#880) 2017-06-29 11:15:59 -07:00
proc.go proc: fix next when current function is unknown on macOS 2017-07-26 12:50:09 -06:00
registers.go proc/core: support floating point registers (#912) 2017-07-20 13:04:00 -06:00
stack.go proc: tolerate memory read errors during stacktrace 2017-07-26 12:50:09 -06:00
threads.go proc: fix next when current function is unknown on macOS 2017-07-26 12:50:09 -06:00
types.go proc/eval: optimize variable lookup (#925) 2017-07-18 12:55:24 -06:00
variables.go proc/eval: optimize variable lookup (#925) 2017-07-18 12:55:24 -06:00