Mailing List archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[vdr] Re: VDR Bug: Question on CAM behavior
Hi Reinhard,
I've modified the patch like you mentioned.
Now the time can simply be editet in the Setup->timers and it will delay the
timer only if CA != 0.
Bye
--
------------------------
Currently used Version: GnuPG V1.2.2
PGP-Key: http://www.afisys.net/keys/andreas.pub.key
diff -Nru vdr-1.1.33/config.c vdr-1.1.33-ctd/config.c
--- vdr-1.1.33/config.c 2003-05-11 15:50:02.000000000 +0200
+++ vdr-1.1.33-ctd/config.c 2003-05-29 15:56:49.000000000 +0200
@@ -286,6 +286,7 @@
memset(CaCaps, sizeof(CaCaps), 0);
CurrentChannel = -1;
CurrentVolume = MAXVOLUME;
+ CryptTimerDelay = 0;
}
cSetup& cSetup::operator= (const cSetup &s)
@@ -437,6 +438,7 @@
else if (!strcasecmp(Name, "CaCaps")) return ParseCaCaps(Value);
else if (!strcasecmp(Name, "CurrentChannel")) CurrentChannel = atoi(Value);
else if (!strcasecmp(Name, "CurrentVolume")) CurrentVolume = atoi(Value);
+ else if (!strcasecmp(Name, "CryptTimerDelay")) CryptTimerDelay = atoi(Value);
else
return false;
return true;
@@ -486,7 +488,8 @@
StoreCaCaps("CaCaps");
Store("CurrentChannel", CurrentChannel);
Store("CurrentVolume", CurrentVolume);
-
+ Store("CryptTimerDelay", CryptTimerDelay);
+
Sort();
if (cConfig<cSetupLine>::Save()) {
diff -Nru vdr-1.1.33/config.h vdr-1.1.33-ctd/config.h
--- vdr-1.1.33/config.h 2003-05-19 17:27:37.000000000 +0200
+++ vdr-1.1.33-ctd/config.h 2003-05-29 15:56:49.000000000 +0200
@@ -235,6 +235,7 @@
int CaCaps[MAXDEVICES][MAXCACAPS];
int CurrentChannel;
int CurrentVolume;
+ int CryptTimerDelay;
int __EndData__;
cSetup(void);
cSetup& operator= (const cSetup &s);
diff -Nru vdr-1.1.33/menu.c vdr-1.1.33-ctd/menu.c
--- vdr-1.1.33/menu.c 2003-05-25 16:06:17.000000000 +0200
+++ vdr-1.1.33-ctd/menu.c 2003-05-29 15:56:49.000000000 +0200
@@ -2217,6 +2217,7 @@
Add(new cMenuEditBoolItem(tr("Setup.Recording$Record Dolby Digital"), &data.RecordDolbyDigital));
Add(new cMenuEditIntItem( tr("Setup.Recording$Max. video file size (MB)"), &data.MaxVideoFileSize, MINVIDEOFILESIZE, MAXVIDEOFILESIZE));
Add(new cMenuEditBoolItem(tr("Setup.Recording$Split edited files"), &data.SplitEditedFiles));
+ Add(new cMenuEditIntItem( tr("Setup.Recording$Crypt timer delay (s)"), &data.CryptTimerDelay, 0, 3600));
}
// --- cMenuSetupReplay ------------------------------------------------------
diff -Nru vdr-1.1.33/vdr.c vdr-1.1.33-ctd/vdr.c
--- vdr-1.1.33/vdr.c 2003-05-24 17:17:38.000000000 +0200
+++ vdr-1.1.33-ctd/vdr.c 2003-05-29 15:58:02.000000000 +0200
@@ -87,6 +87,7 @@
// Initiate locale:
setlocale(LC_ALL, "");
+ time_t StartTime = time(NULL);
// Command line options:
@@ -501,7 +502,7 @@
time_t Now = time(NULL); // must do both following calls with the exact same time!
cRecordControls::Process(Now);
cTimer *Timer = Timers.GetMatch(Now);
- if (Timer) {
+ if ( Timer && ((time(NULL) - StartTime >= Setup.CryptTimerDelay) || (Timer->Channel()->Ca() == 0)) ) {
if (!cRecordControls::Start(Timer))
Timer->SetPending(true);
else
Home |
Main Index |
Thread Index