Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
mpegts network: Fix the issue with no predefined muxes at the network…
… creation
  • Loading branch information
perexg committed Aug 12, 2014
1 parent 34dd2b8 commit 5a621b2
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/input/mpegts/mpegts_network_dvb.c
Expand Up @@ -75,7 +75,7 @@ dvb_network_class_scanfile_set ( void *o, const void *s )
return 0;
if (!(sfn = scanfile_find(s)))
return 0;

/* Create */
LIST_FOREACH(dmc, &sfn->sfn_muxes, dmc_link) {
if (!(mm = dvb_network_find_mux(ln, dmc, MPEGTS_ONID_NONE, MPEGTS_TSID_NONE))) {
Expand Down Expand Up @@ -514,6 +514,7 @@ dvb_network_create0
dvb_network_t *ln;
htsmsg_t *c, *e;
htsmsg_field_t *f;
const char *s;

ln = calloc(1, sizeof(dvb_network_t));
if (idc == &dvb_network_dvbt_class)
Expand Down Expand Up @@ -541,6 +542,11 @@ dvb_network_create0
if (!conf)
return ln;

/* Set predefined muxes */
/* Because PO_NOSAVE in idnode_load() this value is not set on load */
if ((s = htsmsg_get_str(conf, "scanfile")) != NULL)
dvb_network_class_scanfile_set(ln, s);

/* Load muxes */
if ((c = hts_settings_load_r(1, "input/dvb/networks/%s/muxes", uuid))) {
HTSMSG_FOREACH(f, c) {
Expand Down

0 comments on commit 5a621b2

Please sign in to comment.