From a35bcd01c59e9fcb3775b8f2e8d36dcbe526caac Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Sun, 9 Oct 2022 13:27:58 +0200 Subject: [PATCH] pkg/pidfile: replace uses of windows.Close() with windows.CloseHandle() Since https://golang.org/cl/4600042, Close is a straight wrapper of CloseHandle. Signed-off-by: Sebastiaan van Stijn --- pkg/pidfile/pidfile_windows.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/pidfile/pidfile_windows.go b/pkg/pidfile/pidfile_windows.go index 2e7d8112a3..cc22ba4fd2 100644 --- a/pkg/pidfile/pidfile_windows.go +++ b/pkg/pidfile/pidfile_windows.go @@ -11,7 +11,7 @@ func processExists(pid int) bool { } var c uint32 err = windows.GetExitCodeProcess(h, &c) - windows.Close(h) + _ = windows.CloseHandle(h) if err != nil { // From the GetExitCodeProcess function (processthreadsapi.h) API docs: // https://learn.microsoft.com/en-us/windows/win32/api/processthreadsapi/nf-processthreadsapi-getexitcodeprocess