]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
cwc: fixed problem with changed CA pids by provider and prefered CA pid
authorxhaggi <sascha.woo@gmail.com>
Wed, 20 Feb 2013 13:24:11 +0000 (14:24 +0100)
committerAdam Sutton <dev@adamsutton.me.uk>
Thu, 21 Feb 2013 16:00:01 +0000 (16:00 +0000)
(cherry picked from commit b77c68e6e8a453aeefa679b58fe8313044ee5876)

src/cwc.c

index 3c0b5ae93bb64c98678fe0e126aba8001e155be1..5de7b8399af405c8c33e05f3f2cce13785af740e 100644 (file)
--- a/src/cwc.c
+++ b/src/cwc.c
@@ -1,6 +1,6 @@
 /*
  *  tvheadend, CWC interface
- *  Copyright (C) 2007 Andreas Öman
+ *  Copyright (C) 2007 Andreas Öman
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU General Public License as published by
@@ -1636,19 +1636,11 @@ cwc_table_input(struct th_descrambler *td, struct service *t,
     }
 
     if (ct->cs_okchannel == -3 && t->s_prefcapid != 0) {
-      if (t->s_prefcapid == st->es_pid) {
         ep = calloc(1, sizeof(ecm_pid_t));
         ep->ep_pid = t->s_prefcapid;
         LIST_INSERT_HEAD(&ct->cs_pids, ep, ep_link);
         tvhlog(LOG_DEBUG, "cwc", "Insert only one new ECM channel %d for service id %d", t->s_prefcapid, sid);
-      } else {
-        // check if prefcapid wrong
-        struct elementary_stream *prefca = service_stream_find(t, t->s_prefcapid);
-
-        if (!prefca || prefca->es_type != SCT_CA) {
-          t->s_prefcapid = 0;
-        }
-      }
+        ct->cs_okchannel = -4;
     }
 
     if (ct->cs_okchannel == -1 || (ct->cs_okchannel == -3 && t->s_prefcapid == 0)) {