mpegts: fix scanning issue and lfe display name
Still have a problem with dup services being created when scanning with multiple adapters.
This commit is contained in:
parent
ff3bc4c35a
commit
fbd34be472
3 changed files with 9 additions and 4 deletions
|
@ -143,8 +143,7 @@ linuxdvb_frontend_is_enabled ( mpegts_input_t *mi )
|
|||
static void
|
||||
linuxdvb_frontend_display_name ( mpegts_input_t* mi, char *buf, size_t len )
|
||||
{
|
||||
linuxdvb_frontend_t *lfe = (linuxdvb_frontend_t*)mi;
|
||||
strncpy(buf, lfe->lh_displayname ?: "unknown", len);
|
||||
strncpy(buf, linuxdvb_frontend_class_get_title(&mi->mi_id), len);
|
||||
}
|
||||
|
||||
#if 0
|
||||
|
|
|
@ -198,10 +198,18 @@ mpegts_input_is_free ( mpegts_input_t *mi )
|
|||
int
|
||||
mpegts_input_current_weight ( mpegts_input_t *mi )
|
||||
{
|
||||
const mpegts_mux_instance_t *mmi;
|
||||
const service_t *s;
|
||||
const th_subscription_t *ths;
|
||||
int w = 0;
|
||||
|
||||
LIST_FOREACH(mmi, &mi->mi_mux_active, mmi_active_link) {
|
||||
if (mmi->mmi_mux->mm_initial_scan_status == MM_SCAN_CURRENT) {
|
||||
w = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
pthread_mutex_lock(&mi->mi_delivery_mutex);
|
||||
LIST_FOREACH(s, &mi->mi_transports, s_active_link) {
|
||||
LIST_FOREACH(ths, &s->s_subscriptions, ths_service_link)
|
||||
|
|
|
@ -156,7 +156,6 @@ mpegts_mux_start ( mpegts_mux_t *mm, const char *reason, int weight )
|
|||
|
||||
/* Try and remove a lesser instance */
|
||||
if (!mmi) {
|
||||
#if 0
|
||||
LIST_FOREACH(mmi, &mm->mm_instances, mmi_mux_link) {
|
||||
|
||||
/* Bad - skip */
|
||||
|
@ -167,7 +166,6 @@ mpegts_mux_start ( mpegts_mux_t *mm, const char *reason, int weight )
|
|||
if (weight > mmi->mmi_input->mi_current_weight(mmi->mmi_input))
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (mmi)
|
||||
tvhtrace("mpegts", "%s - found mmi %p to boot", buf, mmi);
|
||||
|
|
Loading…
Add table
Reference in a new issue