Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
mpegts: fix mpegts_mux_unsubscribe_by_name() - use right list
  • Loading branch information
perexg committed Mar 11, 2015
1 parent 8b7c67a commit 7cafa5e
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions src/input/mpegts/mpegts_mux.c
Expand Up @@ -1152,19 +1152,16 @@ void
mpegts_mux_unsubscribe_by_name
( mpegts_mux_t *mm, const char *name )
{
mpegts_mux_instance_t *mmi;
const service_t *t;
th_subscription_t *s, *n;

LIST_FOREACH(mmi, &mm->mm_instances, mmi_mux_link) {
s = LIST_FIRST(&subscriptions);
while (s) {
n = LIST_NEXT(s, ths_global_link);
t = s->ths_service;
if (t && t->s_type == STYPE_RAW && !strcmp(s->ths_title, name))
subscription_unsubscribe(s, 0);
s = n;
}
s = LIST_FIRST(&mm->mm_raw_subs);
while (s) {
n = LIST_NEXT(s, ths_global_link);
t = s->ths_service;
if (t && t->s_type == STYPE_RAW && !strcmp(s->ths_title, name))
subscription_unsubscribe(s, 0);
s = n;
}
}

Expand Down

0 comments on commit 7cafa5e

Please sign in to comment.