summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Brainman <alex.brainman@gmail.com>2010-06-11 00:53:54 -0700
committerAlex Brainman <alex.brainman@gmail.com>2010-06-11 00:53:54 -0700
commit3e249b78c6b1e3caec2532dd15d94db6adefac55 (patch)
tree2e54c1c9b29618f72d26e339382f9804aff99392
parent8796ea51a94b4db6b1c2dc62ad83815c591d554f (diff)
downloadgolang-3e249b78c6b1e3caec2532dd15d94db6adefac55.tar.gz
runtime: free lock handles on Windows
R=rsc CC=golang-dev http://codereview.appspot.com/1652041 Committer: Russ Cox <rsc@golang.org>
-rw-r--r--src/pkg/runtime/windows/thread.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/pkg/runtime/windows/thread.c b/src/pkg/runtime/windows/thread.c
index b5f8cc033..21b679b33 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