[vlc-devel] [PATCH] Global Hotkeys for windows
Rémi Denis-Courmont
rdenis at simphalempin.com
Tue Jan 13 09:16:57 CET 2009
On Tue, 13 Jan 2009 07:23:34 +0000 (GMT), Hannes Domani <ssbssa at yahoo.de>
wrote:
>> (Do not forget the vlc_savecancel/vlc_restorecancel calls
>> in Thread().
> i don't really get why those are still necessary if i have another way to
> tell the thread to return.
If vlc_cancel() is never invoked against your thread, then you don't need
these indeed. If you use vlc_clone() manually, and you are using a
different mechanism to deliver the exit event to your thread, then that
works.
However, if you use vlc_thread_create(), then vlc_object_kill() will call
vlc_cancel() automatically. Then again, with vlc_thread_create(), Close()
would _not_ be called until the thread exits, so you'd deadlock anyway.
LibVLC core waits for pf_run (if not NULL) to return before it calls
Close().
--
Rémi Denis-Courmont
More information about the vlc-devel
mailing list