iptv: fix lock ordeirng bug

This commit is contained in:
Adam Sutton 2013-11-30 21:31:31 +00:00
parent fcc97df55c
commit d1eabea12d

View file

@ -220,12 +220,12 @@ iptv_input_stop_mux ( mpegts_input_t *mi, mpegts_mux_instance_t *mmi )
if (!im->mm_active)
return;
pthread_mutex_lock(&iptv_lock);
/* Stop */
if (im->im_handler->stop)
im->im_handler->stop(im);
pthread_mutex_lock(&iptv_lock);
/* Close file */
if (im->mm_iptv_fd > 0) {
close(im->mm_iptv_fd); // removes from poll