mpegts: fix possible recursion, causing strange crashes

I'm not entirely sure what has changed that has made this a problem
where it apparently wasn't before. That being said, its not nice and
would previously have said it might cause undesirable side-effects.
I would have been right!
This commit is contained in:
Adam Sutton 2014-06-09 21:13:22 +01:00
parent e722e48324
commit a68d867cb3

View file

@ -576,6 +576,10 @@ mpegts_mux_stop ( mpegts_mux_t *mm, int force )
if (!force && mpegts_mux_has_subscribers(mm))
return;
/* Stop possible recursion */
if (!mmi) return;
mm->mm_active = NULL;
mm->mm_display_name(mm, buf, sizeof(buf));
tvhdebug("mpegts", "%s - stopping mux", buf);