[MPlayer-dev-eng] [PATCH] Better handling of win32 GUI thread

Zuxy Meng zuxy.meng at gmail.com
Tue Nov 6 10:59:52 CET 2007


Hi,

2007/11/1, Zuxy Meng <zuxy.meng at gmail.com>:
> Hi,
>
> The attached patch contains two fixes:
>
> 1. Use _beginthreadex instead of CreateThread to create the thread so
> as to avoid a small memory leak when mplayer is linked to MS CRT.
>
> 2. Remove the call to TerminateThread(). For one thing this isn't the
> recommended way to terminate a thread; for another it's called with an
> incorrect argument and therefore has always failed: the first
> parameter should be a handle to the thread instead of the thread
> function. And without this call the GUI thread will terminate itself
> anyway once mygui == NULL.

Update patch that will free the GUI thread in a cleaner way.

-- 
Zuxy
Beauty is truth,
While truth is beauty.
PGP KeyID: E8555ED6
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: interface.c.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20071106/6ffcf636/attachment.txt>


More information about the MPlayer-dev-eng mailing list