[vlc-commits] commit: Win32(core): _endthreadex(0) instead of _endthread() (Erwan Tulou )

git at videolan.org git at videolan.org
Thu Jun 10 23:25:27 CEST 2010


vlc | branch: master | Erwan Tulou <erwan10 at videolan.org> | Wed Feb 10 13:15:00 2010 +0100| [99f71e5a62fdd14b031fdc89f452d873e3509c74] | committer: Erwan Tulou 

Win32(core): _endthreadex(0) instead of _endthread()

According to msdn doc, _endthreadex(0) is to be used when thread is
 launched with _beginthreadex().

Note that when returning from the normal path, an implicit _endthreadex is
issued anyway.  It is important to be consistent whatever the path, since
those final functions (_endthread, ExitThread, _endthreadex) don't have
the same deallocation policy.

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

 src/win32/thread.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/win32/thread.c b/src/win32/thread.c
index dfeed9a..b2e939d 100644
--- a/src/win32/thread.c
+++ b/src/win32/thread.c
@@ -698,7 +698,7 @@ void vlc_testcancel (void)
         for (vlc_cleanup_t *p = nfo->cleaners; p != NULL; p = p->next)
              p->proc (p->data);
 #ifndef UNDER_CE
-        _endthread ();
+        _endthreadex(0);
 #else
         ExitThread(0);
 #endif



More information about the vlc-commits mailing list