[vlc-devel] commit: vlc: Make sure we call libvlc_release()when we are requested to die. (Pierre d'Herbemont )

Remi Denis-Courmont rdenis at simphalempin.com
Fri May 16 08:36:33 CEST 2008


On Thu, 15 May 2008 23:01:08 +0200, Pierre d'Herbemont
<pdherbemont at free.fr> wrote:
>> IMHO, we should not handle Ctrl+C at all. Most GUI program don't.
> 
> I don't like that much programs that don't respond to Ctrl-C. But  
> that's a taste question. Feel free to do whatever you prefer, here.

I too used it as a convenience. But releasing an object while another
thread is still using it is against all logic (and sanity). The only proper
way would be through a "wait-for-VLC-or-something-else" API, such as a
libvlc_ppoll(libvlc_instance_t *, struct pollfd *fds, unsigned n, struct
timespec *timeout, const sigset_t *sigset);

That would be a little bit challenging to integrate with the current
AddIntf() (uses a condition variable), but it's do-able. Of course, that
would break any interface that sets b_main_thread... choose your side.

-- 
Rémi Denis-Courmont
http://www.remlab.net




More information about the vlc-devel mailing list