From fdb460ec11500881ecfd57abd93a9c1e409898b7 Mon Sep 17 00:00:00 2001 From: Alex Brainman Date: Fri, 11 Jun 2010 00:53:54 -0700 Subject: [PATCH] runtime: free lock handles on Windows R=rsc CC=golang-dev https://golang.org/cl/1652041 --- src/pkg/runtime/windows/thread.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/pkg/runtime/windows/thread.c b/src/pkg/runtime/windows/thread.c index b5f8cc0330a..21b679b3312 100644 --- a/src/pkg/runtime/windows/thread.c +++ b/src/pkg/runtime/windows/thread.c @@ -220,6 +220,8 @@ unlock(Lock *l) void destroylock(Lock *l) { + if(l->event != 0) + stdcall(CloseHandle, 1, l->event); } void