diff --git a/dvb_dvr.c b/dvb_dvr.c index 4f46dcfd..712cca53 100644 --- a/dvb_dvr.c +++ b/dvb_dvr.c @@ -149,20 +149,15 @@ dvb_start_feed(th_transport_t *t, unsigned int weight) LIST_FOREACH(tdmi, &mux->tdm_instances, tdmi_mux_link) { + if(tdmi->tdmi_state == TDMI_RUNNING) + goto gotmux; + if(tdmi->tdmi_status != NULL) continue; /* no lock */ if(tdmi->tdmi_fec_err_per_sec > DVB_FEC_ERROR_LIMIT / 3) continue; /* too much errors to even consider */ - if(tdmi->tdmi_state == TDMI_RUNNING) - goto gotmux; - - if(tdmi->tdmi_state == TDMI_IDLESCAN) { - tdmi->tdmi_state = TDMI_RUNNING; - goto gotmux; - } - w = transport_compute_weight(&tdmi->tdmi_adapter->tda_transports); if(w < weight && cand == NULL) cand = tdmi;