vlc | branch: master | Hannes Domani <ssb...@yahoo.de> | Thu Aug 28 13:22:33 
2014 +0200| [b1f9242606caf549a03c6b11b00c66c2c1af27cb] | committer: 
Jean-Baptiste Kempf

Win32 threads: fix memory leak of detached thread

Signed-off-by: Jean-Baptiste Kempf <j...@videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=b1f9242606caf549a03c6b11b00c66c2c1af27cb
---

 src/win32/thread.c |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/win32/thread.c b/src/win32/thread.c
index ed3c4f9..fe17ad5 100644
--- a/src/win32/thread.c
+++ b/src/win32/thread.c
@@ -503,7 +503,10 @@ static int vlc_clone_attr (vlc_thread_t *p_handle, bool 
detached,
     }
 
     if (detached)
+    {
         CloseHandle((HANDLE)h);
+        th->id = NULL;
+    }
     else
         th->id = (HANDLE)h;
 

_______________________________________________
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to