Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
mpegts input: fix the linked input unset action
  • Loading branch information
perexg committed Jan 18, 2015
1 parent a2c01ed commit 9801ef1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/input/mpegts/mpegts_input.c
Expand Up @@ -155,15 +155,16 @@ mpegts_input_class_linked_set ( void *self, const void *val )
mpegts_mux_unsubscribe_linked(mi2);
}
mpegts_mux_unsubscribe_linked(mi);
if (val) {
if (val && ((char *)val)[0]) {
mi->mi_linked = strdup((char *)val);
mi2 = mpegts_input_find((char *)val);
if (mi2) {
free(mi2->mi_linked);
mi2->mi_linked = strdup(idnode_uuid_as_str(&mi->ti_id));
idnode_changed(&mi2->ti_id);
}
}
if (mi2)
idnode_changed(&mi2->ti_id);
return 1;
}
return 0;
Expand Down

0 comments on commit 9801ef1

Please sign in to comment.