summaryrefslogtreecommitdiff
path: root/dvbapi.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2001-01-18 19:53:54 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2001-01-18 19:53:54 +0100
commit40b599f1c793ec7b485f626d444044de387cf204 (patch)
treeadf939fd66cdaf22749b05a722c30fe62b1755b2 /dvbapi.c
parent3ab1a8602802b3225b91fc8bf7977b2d74b28e5d (diff)
downloadvdr-40b599f1c793ec7b485f626d444044de387cf204.tar.gz
vdr-40b599f1c793ec7b485f626d444044de387cf204.tar.bz2
Encrypted channels no longer need PNR
Diffstat (limited to 'dvbapi.c')
-rw-r--r--dvbapi.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/dvbapi.c b/dvbapi.c
index 54f6fe53..e583baf9 100644
--- a/dvbapi.c
+++ b/dvbapi.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: dvbapi.c 1.49 2001/01/18 17:03:34 kls Exp $
+ * $Id: dvbapi.c 1.50 2001/01/18 19:53:54 kls Exp $
*/
#include "dvbapi.h"
@@ -844,6 +844,12 @@ int cRecordBuffer::Synchronize(void)
pictureType = NO_PICTURE;
+ //XXX remove this once the buffer is handled with two separate threads:
+ if (!synced && Free() < 100000) {
+ dsyslog(LOG_INFO, "unable to synchronize, dropped %d bytes", Available());
+ Clear();
+ return 0;
+ }
for (int i = 0; Available() > MINVIDEODATA && i < MINVIDEODATA; i++) {
if (Byte(i) == 0 && Byte(i + 1) == 0 && Byte(i + 2) == 1) {
switch (Byte(i + 3)) {
@@ -2176,8 +2182,7 @@ bool cDvbApi::SetChannel(int ChannelNumber, int FrequencyMHz, char Polarization,
freq -= Setup.LnbFrequLo;
else
freq -= Setup.LnbFrequHi;
- front.channel_flags = Ca ? DVB_CHANNEL_CA : DVB_CHANNEL_FTA;
- front.pnr = Pnr;
+ front.pnr = 0;
front.freq = freq * 1000000UL;
front.diseqc = Diseqc;
front.srate = Srate * 1000;