From 933b4883777717452d11c613bbd2d355bd714956 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20=C3=96man?= Date: Wed, 21 Nov 2007 15:32:41 +0000 Subject: [PATCH] if the tdmi is running, trust it above all else --- dvb_dvr.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) 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;