iptv: allow setting of default (single) service name in mux config
This commit is contained in:
parent
5552b7379b
commit
eb089e0e88
3 changed files with 14 additions and 0 deletions
|
@ -50,6 +50,12 @@ const idclass_t iptv_mux_class =
|
|||
.name = "ATSC",
|
||||
.off = offsetof(iptv_mux_t, mm_iptv_atsc),
|
||||
},
|
||||
{
|
||||
.type = PT_STR,
|
||||
.id = "iptv_svcname",
|
||||
.name = "Service Name",
|
||||
.off = offsetof(iptv_mux_t, mm_iptv_svcname),
|
||||
},
|
||||
{}
|
||||
}
|
||||
};
|
||||
|
|
|
@ -83,9 +83,12 @@ struct iptv_mux
|
|||
uint8_t *mm_iptv_tsb;
|
||||
int mm_iptv_pos;
|
||||
|
||||
char *mm_iptv_svcname;
|
||||
|
||||
iptv_handler_t *im_handler;
|
||||
|
||||
void *im_data;
|
||||
|
||||
};
|
||||
|
||||
iptv_mux_t* iptv_mux_create ( const char *uuid, htsmsg_t *conf );
|
||||
|
|
|
@ -49,5 +49,10 @@ iptv_service_create0
|
|||
|
||||
is->s_config_save = iptv_service_config_save;
|
||||
|
||||
/* Set default service name */
|
||||
if (!is->s_dvb_svcname || !*is->s_dvb_svcname)
|
||||
if (im->mm_iptv_svcname)
|
||||
is->s_dvb_svcname = strdup(im->mm_iptv_svcname);
|
||||
|
||||
return is;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue