Version 1.4.4-1

- Some improvements to the man pages (thanks to Ville Skyttä).
- Fixed a possible segfault in cSkins::Message() (thanks to Udo Richter).
- Made the getskyepg.pl script of the 'sky' plugin send a user agent message to
  the server, according to the rules at http://bleb.org/tv/data/listings.
  If your version of 'wget' doesn't support the -U option to set the user agent,
  use the new option -U of getskyepg.pl to have the information added to the URL
  as a query string.
- The getskyepg.pl script now replaces "&" with "&".
- Fixed a possible crash in remux.c on 64-bit machines (thanks to Reinhard Nissl).
- Fixed a typo in the change to the "Use small font" setup option in version 1.3.47
  in the HISTORY and CONTRIBUTORS file (reported by Andreas Brugger).
- Added a missing 'const' to cRecordingInfo::ChannelID() (reported by Andreas
  Brugger). This required the APIVERSION to be increased, so plugins will have to
  be recompiled.
- Now calling cPluginManager::Active() only if VDR is really trying to shut down,
  and waiting for 5 minutes before calling it again (thanks to Jörg Wendel for
  reporting that cPlugin::Active() was called too often, and to Udo Richter for
  some hints on how to improve this).
- Replaced 'unsigned long' with 'uint32_t' and 'uint64' with 'uint64_t' to
  avoid problems on 64-bit machines.
This commit is contained in:
Klaus Schmidinger 2006-12-03 18:00:00 +01:00
parent bc67a03157
commit 287cd613a1
18 changed files with 130 additions and 59 deletions

View File

@ -1113,6 +1113,7 @@ Reinhard Nissl <rnissl@gmx.de>
for implementing cDevice::ForceTransferMode() for implementing cDevice::ForceTransferMode()
for changing the behaviour when hitting the end of a recording in fast forward mode for changing the behaviour when hitting the end of a recording in fast forward mode
for suggesting to give the cRemote::CallPlugin() function a boolean return value for suggesting to give the cRemote::CallPlugin() function a boolean return value
for fixing a possible crash in remux.c on 64-bit machines
Richard Robson <richard_robson@beeb.net> Richard Robson <richard_robson@beeb.net>
for reporting freezing replay if a timer starts while in Transfer Mode from the for reporting freezing replay if a timer starts while in Transfer Mode from the
@ -1474,6 +1475,8 @@ Udo Richter <udo_richter@gmx.de>
for reporting that an assignment in svdrp.c didn't use the cTimer::operator=()) for reporting that an assignment in svdrp.c didn't use the cTimer::operator=())
for suggesting that the function cThread::Cancel() should only set 'running' to for suggesting that the function cThread::Cancel() should only set 'running' to
false and not actually kill the thread if the special value -1 is given false and not actually kill the thread if the special value -1 is given
or fixing a possible segfault in cSkins::Message()
for some hints on how to improve handling cPluginManager::Active()
Sven Kreiensen <svenk@kammer.uni-hannover.de> Sven Kreiensen <svenk@kammer.uni-hannover.de>
for his help in keeping 'channels.conf.terr' up to date for his help in keeping 'channels.conf.terr' up to date
@ -1521,6 +1524,9 @@ Andreas Brugger <brougs78@gmx.net>
cStatus::Replaying(), so that they can provide the full file name of the recording cStatus::Replaying(), so that they can provide the full file name of the recording
for suggesting that externally provided EPG data (with table ID 0x00) shall get its for suggesting that externally provided EPG data (with table ID 0x00) shall get its
component descriptors set from the broadcast data component descriptors set from the broadcast data
for reporting a typo in the change to the "Use small font" setup option in version
1.3.47 in the HISTORY and CONTRIBUTORS file
for reporting a missing 'const' in cRecordingInfo::ChannelID()
Dino Ravnic <dino.ravnic@fer.hr> Dino Ravnic <dino.ravnic@fer.hr>
for fixing some characters in the iso8859-2 font file for fixing some characters in the iso8859-2 font file
@ -1638,6 +1644,7 @@ Ville Skytt
for fixing converting the port number in the "connect from..." log message of SVDRP for fixing converting the port number in the "connect from..." log message of SVDRP
for reporting that there are places where ntohs() is assigned to different types for reporting that there are places where ntohs() is assigned to different types
for adapting cThread::ThreadId() to recent kernels for adapting cThread::ThreadId() to recent kernels
for some improvements to the man pages
Steffen Beyer <cpunk@reactor.de> Steffen Beyer <cpunk@reactor.de>
for fixing setting the colored button help after deleting a recording in case the next for fixing setting the colored button help after deleting a recording in case the next
@ -1903,7 +1910,7 @@ Suur Karu <suurkaru@fastmail.fm>
Ronny Kornexl <ronny.kornexl@online.de> Ronny Kornexl <ronny.kornexl@online.de>
for reporting a problem with setting "No title" for broken event data for reporting a problem with setting "No title" for broken event data
for suggesting to make the "Use small font" setup option *always* use the small for suggesting to make the "Use small font" setup option *always* use the small
font if set to '3' - even if it would have been a fixed font font if set to '2' - even if it would have been a fixed font
for reporting a bug in initializing 'noapiv' in the Makefile for reporting a bug in initializing 'noapiv' in the Makefile
Vladimír Bárta <vladimir.barta@k2atmitec.cz> Vladimír Bárta <vladimir.barta@k2atmitec.cz>
@ -2032,3 +2039,6 @@ Boguslaw Juza <bogdan@uci.agh.edu.pl>
Ulf Kiener <webmaster@ulf-kiener.de> Ulf Kiener <webmaster@ulf-kiener.de>
for reporting a problem with audio track descriptions in the DVD plugin after a for reporting a problem with audio track descriptions in the DVD plugin after a
replay has been stopped replay has been stopped
Jörg Wendel <vdr-ml@jwendel.de>
for reporting that cPlugin::Active() was called too often

25
HISTORY
View File

@ -4611,7 +4611,7 @@ Video Disk Recorder Revision History
(since version 1.3.38 disk access is done in a separate thread, so the watchdog (since version 1.3.38 disk access is done in a separate thread, so the watchdog
timer won't hit). timer won't hit).
- Changed the behaviour of the "Use small font" setup option to *always* use the small - Changed the behaviour of the "Use small font" setup option to *always* use the small
font if set to '3' - even if it would have been a fixed font (suggested by Ronny font if set to '2' - even if it would have been a fixed font (suggested by Ronny
Kornexl). Kornexl).
- No longer using characters 0x01 and 0x02 for mapping single quote and slash in - No longer using characters 0x01 and 0x02 for mapping single quote and slash in
recording names (thanks to Patrick Fischer for reporting that this was a problem recording names (thanks to Patrick Fischer for reporting that this was a problem
@ -4985,3 +4985,26 @@ Video Disk Recorder Revision History
- Fixed displaying the replay mode symbol in case of "Multi speed mode" (reported - Fixed displaying the replay mode symbol in case of "Multi speed mode" (reported
by Marco Schlüßler). by Marco Schlüßler).
2006-12-03: Version 1.4.4-1
- Some improvements to the man pages (thanks to Ville Skyttä).
- Fixed a possible segfault in cSkins::Message() (thanks to Udo Richter).
- Made the getskyepg.pl script of the 'sky' plugin send a user agent message to
the server, according to the rules at http://bleb.org/tv/data/listings.
If your version of 'wget' doesn't support the -U option to set the user agent,
use the new option -U of getskyepg.pl to have the information added to the URL
as a query string.
- The getskyepg.pl script now replaces "&amp;" with "&".
- Fixed a possible crash in remux.c on 64-bit machines (thanks to Reinhard Nissl).
- Fixed a typo in the change to the "Use small font" setup option in version 1.3.47
in the HISTORY and CONTRIBUTORS file (reported by Andreas Brugger).
- Added a missing 'const' to cRecordingInfo::ChannelID() (reported by Andreas
Brugger). This required the APIVERSION to be increased, so plugins will have to
be recompiled.
- Now calling cPluginManager::Active() only if VDR is really trying to shut down,
and waiting for 5 minutes before calling it again (thanks to Jörg Wendel for
reporting that cPlugin::Active() was called too often, and to Udo Richter for
some hints on how to improve this).
- Replaced 'unsigned long long' with 'uint32_t' and 'uint64' with 'uint64_t' to
avoid problems on 64-bit machines.

View File

@ -45,3 +45,12 @@ VDR Plugin 'sky' Revision History
2006-03-26: Version 0.3.5 2006-03-26: Version 0.3.5
- Fixed format string handling. - Fixed format string handling.
2006-12-02: Version 0.3.5 (version number not increased)
- Made the getskyepg.pl script send a user agent message to
the server, according to the rules at http://bleb.org/tv/data/listings.
If your version of 'wget' doesn't support the -U option to set the user agent,
use the new option -U of getskyepg.pl to have the information added to the URL
as a query string.
- The getskyepg.pl script now replaces "&amp;" with "&".

View File

@ -8,7 +8,7 @@
# #
# See the README file for copyright information and how to reach the author. # See the README file for copyright information and how to reach the author.
# #
# $Id: getskyepg.pl 1.4 2006/01/08 10:21:32 kls Exp $ # $Id: getskyepg.pl 1.6 2006/12/02 09:52:49 kls Exp $
use Getopt::Std; use Getopt::Std;
use Time::Local; use Time::Local;
@ -21,18 +21,29 @@ Options: -c filename channel config file name (default: channels.conf.sky
-p port SVDRP port number (default: 2001) -p port SVDRP port number (default: 2001)
-S source channel source (default: S28.2E) -S source channel source (default: S28.2E)
-D days days to get EPG for (1..7, default: 2) -D days days to get EPG for (1..7, default: 2)
-U use this if your version of 'wget' doesn't support -U
}; };
die $Usage if (!getopts("c:d:D:hp:S:") || $opt_h); die $Usage if (!getopts("c:d:D:hp:S:U") || $opt_h);
$Conf = $opt_c || "channels.conf.sky"; $Conf = $opt_c || "channels.conf.sky";
$Dest = $opt_d || "localhost"; $Dest = $opt_d || "localhost";
$Port = $opt_p || 2001; $Port = $opt_p || 2001;
$Source = $opt_S || "S28.2E"; $Source = $opt_S || "S28.2E";
$Days = $opt_D || 2; $Days = $opt_D || 2;
$User = $opt_U;
# See "Rules for using this data" on http://bleb.org/tv/data/listings.
# In case you modify this script in a way that changes its behavior
# towards the www.bleb.org website, please replace 'vdrbugs@cadsoft.de'
# with your own email address! That way Andrew Flegg <andrew@bleb.org>,
# who runs that web site, can contact you in case of problems.
$IDENT = "VDR::getskyepg.pl, http://www.cadsoft.de/vdr - vdrbugs\@cadsoft.de";
$GAP = 2;
$SkyWebPage = "www.bleb.org/tv/data/listings"; $SkyWebPage = "www.bleb.org/tv/data/listings";
$WGET = "/usr/bin/wget -q -O-"; $WGET = "/usr/bin/wget -q -O-";
$WGET .= " -U '$IDENT'" unless $User;
$LOGGER = "/usr/bin/logger -t SKYEPG"; $LOGGER = "/usr/bin/logger -t SKYEPG";
$DST = -3600; # Daylight Saving Time offset $DST = -3600; # Daylight Saving Time offset
@ -76,13 +87,21 @@ sub GetPage
my $channel = shift; my $channel = shift;
my $day = shift; my $day = shift;
$day--; $day--;
my $url = "$SkyWebPage/$day/$channel.xml"; my $url = "http://$SkyWebPage/$day/$channel.xml";
$url .= "?$IDENT" if $User;
Log("reading $url"); Log("reading $url");
my @page = split("\n", `$WGET '$url'`); my @page = split("\n", `$WGET '$url'`);
Log("received " . ($#page + 1) . " lines"); Log("received " . ($#page + 1) . " lines");
return @page; return @page;
} }
sub ReplaceTags
{
my $s = shift;
$s =~ s/&amp;/&/g;
return $s;
}
sub StripWhitespace sub StripWhitespace
{ {
my $s = shift; my $s = shift;
@ -96,7 +115,7 @@ sub Extract
my $s = shift; my $s = shift;
my $t = shift; my $t = shift;
$s =~ /<$t>([^<]*)<\/$t>/; $s =~ /<$t>([^<]*)<\/$t>/;
return StripWhitespace($1); return ReplaceTags(StripWhitespace($1));
} }
# In order to get the duration we need to buffer the last event: # In order to get the duration we need to buffer the last event:
@ -174,6 +193,7 @@ sub GetEpgData
$data .= $line; $data .= $line;
} }
} }
sleep($GAP);
} }
SVDRPsend("c"); SVDRPsend("c");
Log("generated $numEvents EPG events"); Log("generated $numEvents EPG events");

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: config.h 1.277 2006/11/04 13:19:31 kls Exp $ * $Id: config.h 1.279 2006/12/01 15:08:43 kls Exp $
*/ */
#ifndef __CONFIG_H #ifndef __CONFIG_H
@ -21,13 +21,13 @@
// VDR's own version number: // VDR's own version number:
#define VDRVERSION "1.4.4" #define VDRVERSION "1.4.4-1"
#define VDRVERSNUM 10404 // Version * 10000 + Major * 100 + Minor #define VDRVERSNUM 10404 // Version * 10000 + Major * 100 + Minor
// The plugin API's version number: // The plugin API's version number:
#define APIVERSION "1.4.4" #define APIVERSION "1.4.5"
#define APIVERSNUM 10404 // Version * 10000 + Major * 100 + Minor #define APIVERSNUM 10405 // Version * 10000 + Major * 100 + Minor
// When loading plugins, VDR searches them by their APIVERSION, which // When loading plugins, VDR searches them by their APIVERSION, which
// may be smaller than VDRVERSION in case there have been no changes to // may be smaller than VDRVERSION in case there have been no changes to

4
font.h
View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: font.h 1.12 2006/02/05 13:46:36 kls Exp $ * $Id: font.h 1.13 2006/12/02 11:11:48 kls Exp $
*/ */
#ifndef __FONT_H #ifndef __FONT_H
@ -32,7 +32,7 @@ enum eDvbCode {
class cFont { class cFont {
public: public:
enum { NUMCHARS = 256 }; enum { NUMCHARS = 256 };
typedef unsigned long tPixelData; typedef uint32_t tPixelData;
struct tCharData { struct tCharData {
tPixelData width, height; tPixelData width, height;
tPixelData lines[1]; tPixelData lines[1];

4
menu.c
View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: menu.c 1.445 2006/11/04 13:13:18 kls Exp $ * $Id: menu.c 1.446 2006/12/02 11:12:02 kls Exp $
*/ */
#include "menu.h" #include "menu.h"
@ -3280,7 +3280,7 @@ eOSState cDisplayChannel::ProcessKey(eKeys Key)
return osEnd; return osEnd;
} }
}; };
if (!timeout || lastTime.Elapsed() < (uint64)(Setup.ChannelInfoTime * 1000)) { if (!timeout || lastTime.Elapsed() < (uint64_t)(Setup.ChannelInfoTime * 1000)) {
if (Key == kNone && !number && group < 0 && !NewChannel && channel && channel->Number() != cDevice::CurrentChannel()) { if (Key == kNone && !number && group < 0 && !NewChannel && channel && channel->Number() != cDevice::CurrentChannel()) {
// makes sure a channel switch through the SVDRP CHAN command is displayed // makes sure a channel switch through the SVDRP CHAN command is displayed
channel = Channels.GetByNumber(cDevice::CurrentChannel()); channel = Channels.GetByNumber(cDevice::CurrentChannel());

8
rcu.c
View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: rcu.c 1.14 2006/06/16 09:29:24 kls Exp $ * $Id: rcu.c 1.15 2006/12/02 11:12:28 kls Exp $
*/ */
#include "rcu.h" #include "rcu.h"
@ -97,7 +97,7 @@ void cRcuRemote::Action(void)
time_t LastCodeRefresh = 0; time_t LastCodeRefresh = 0;
cTimeMs FirstTime; cTimeMs FirstTime;
unsigned char LastCode = 0, LastMode = 0; unsigned char LastCode = 0, LastMode = 0;
uint64 LastCommand = ~0; // 0x00 might be a valid command uint64_t LastCommand = ~0; // 0x00 might be a valid command
unsigned int LastData = 0; unsigned int LastData = 0;
bool repeat = false; bool repeat = false;
@ -109,13 +109,13 @@ void cRcuRemote::Action(void)
buffer.raw[i] = b; buffer.raw[i] = b;
if (i == 5) { if (i == 5) {
unsigned short Address = ntohs(buffer.data.address); // the PIC sends bytes in "network order" unsigned short Address = ntohs(buffer.data.address); // the PIC sends bytes in "network order"
uint64 Command = ntohl(buffer.data.command); uint64_t Command = ntohl(buffer.data.command);
if (code == 'B' && Address == 0x0000 && Command == 0x00004000) if (code == 'B' && Address == 0x0000 && Command == 0x00004000)
// Well, well, if it isn't the "d-box"... // Well, well, if it isn't the "d-box"...
// This remote control sends the above command before and after // This remote control sends the above command before and after
// each keypress - let's just drop this: // each keypress - let's just drop this:
break; break;
Command |= uint64(Address) << 32; Command |= uint64_t(Address) << 32;
if (Command != LastCommand) { if (Command != LastCommand) {
LastCommand = Command; LastCommand = Command;
repeat = false; repeat = false;

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: recording.h 1.55 2006/07/30 10:24:07 kls Exp $ * $Id: recording.h 1.56 2006/12/01 15:06:07 kls Exp $
*/ */
#ifndef __RECORDING_H #ifndef __RECORDING_H
@ -50,7 +50,7 @@ private:
void SetAux(const char *Aux); void SetAux(const char *Aux);
public: public:
~cRecordingInfo(); ~cRecordingInfo();
tChannelID ChannelID(void) { return channelID; } tChannelID ChannelID(void) const { return channelID; }
const char *Title(void) const { return event->Title(); } const char *Title(void) const { return event->Title(); }
const char *ShortText(void) const { return event->ShortText(); } const char *ShortText(void) const { return event->ShortText(); }
const char *Description(void) const { return event->Description(); } const char *Description(void) const { return event->Description(); }

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: remote.c 1.54 2006/10/14 11:05:57 kls Exp $ * $Id: remote.c 1.55 2006/12/02 11:12:42 kls Exp $
*/ */
#include "remote.h" #include "remote.h"
@ -116,7 +116,7 @@ bool cRemote::PutMacro(eKeys Key)
return true; return true;
} }
bool cRemote::Put(uint64 Code, bool Repeat, bool Release) bool cRemote::Put(uint64_t Code, bool Repeat, bool Release)
{ {
char buffer[32]; char buffer[32];
snprintf(buffer, sizeof(buffer), "%016LX", Code); snprintf(buffer, sizeof(buffer), "%016LX", Code);
@ -203,7 +203,7 @@ cRemotes Remotes;
struct tKbdMap { struct tKbdMap {
eKbdFunc func; eKbdFunc func;
uint64 code; uint64_t code;
}; };
static tKbdMap KbdMap[] = { static tKbdMap KbdMap[] = {
@ -264,7 +264,7 @@ void cKbdRemote::SetRawMode(bool RawMode)
rawMode = RawMode; rawMode = RawMode;
} }
uint64 cKbdRemote::MapFuncToCode(int Func) uint64_t cKbdRemote::MapFuncToCode(int Func)
{ {
for (tKbdMap *p = KbdMap; p->func != kfNone; p++) { for (tKbdMap *p = KbdMap; p->func != kfNone; p++) {
if (p->func == Func) if (p->func == Func)
@ -273,7 +273,7 @@ uint64 cKbdRemote::MapFuncToCode(int Func)
return (Func <= 0xFF) ? Func : 0; return (Func <= 0xFF) ? Func : 0;
} }
int cKbdRemote::MapCodeToFunc(uint64 Code) int cKbdRemote::MapCodeToFunc(uint64_t Code)
{ {
for (tKbdMap *p = KbdMap; p->func != kfNone; p++) { for (tKbdMap *p = KbdMap; p->func != kfNone; p++) {
if (p->code == Code) if (p->code == Code)
@ -296,9 +296,9 @@ int cKbdRemote::ReadKey(void)
return -1; return -1;
} }
uint64 cKbdRemote::ReadKeySequence(void) uint64_t cKbdRemote::ReadKeySequence(void)
{ {
uint64 k = 0; uint64_t k = 0;
int key1; int key1;
if ((key1 = ReadKey()) >= 0) { if ((key1 = ReadKey()) >= 0) {
@ -342,7 +342,7 @@ uint64 cKbdRemote::ReadKeySequence(void)
void cKbdRemote::Action(void) void cKbdRemote::Action(void)
{ {
while (Running()) { while (Running()) {
uint64 Command = ReadKeySequence(); uint64_t Command = ReadKeySequence();
if (Command) { if (Command) {
if (rawMode || !Put(Command)) { if (rawMode || !Put(Command)) {
int func = MapCodeToFunc(Command); int func = MapCodeToFunc(Command);

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: remote.h 1.37 2006/10/14 11:46:58 kls Exp $ * $Id: remote.h 1.38 2006/12/02 11:12:49 kls Exp $
*/ */
#ifndef __REMOTE_H #ifndef __REMOTE_H
@ -35,7 +35,7 @@ protected:
cRemote(const char *Name); cRemote(const char *Name);
const char *GetSetup(void); const char *GetSetup(void);
void PutSetup(const char *Setup); void PutSetup(const char *Setup);
bool Put(uint64 Code, bool Repeat = false, bool Release = false); bool Put(uint64_t Code, bool Repeat = false, bool Release = false);
bool Put(const char *Code, bool Repeat = false, bool Release = false); bool Put(const char *Code, bool Repeat = false, bool Release = false);
public: public:
virtual ~cRemote(); virtual ~cRemote();
@ -100,13 +100,13 @@ private:
struct termios savedTm; struct termios savedTm;
virtual void Action(void); virtual void Action(void);
int ReadKey(void); int ReadKey(void);
uint64 ReadKeySequence(void); uint64_t ReadKeySequence(void);
int MapCodeToFunc(uint64 Code); int MapCodeToFunc(uint64_t Code);
public: public:
cKbdRemote(void); cKbdRemote(void);
virtual ~cKbdRemote(); virtual ~cKbdRemote();
static bool KbdAvailable(void) { return kbdAvailable; } static bool KbdAvailable(void) { return kbdAvailable; }
static uint64 MapFuncToCode(int Func); static uint64_t MapFuncToCode(int Func);
static void SetRawMode(bool RawMode); static void SetRawMode(bool RawMode);
}; };

View File

@ -11,7 +11,7 @@
* The cRepacker family's code was originally written by Reinhard Nissl <rnissl@gmx.de>, * The cRepacker family's code was originally written by Reinhard Nissl <rnissl@gmx.de>,
* and adapted to the VDR coding style by Klaus.Schmidinger@cadsoft.de. * and adapted to the VDR coding style by Klaus.Schmidinger@cadsoft.de.
* *
* $Id: remux.c 1.56 2006/04/17 12:48:12 kls Exp $ * $Id: remux.c 1.57 2006/12/01 14:46:25 kls Exp $
*/ */
#include "remux.h" #include "remux.h"
@ -389,7 +389,7 @@ bool cVideoRepacker::ScanDataForStartCodeFast(const uchar *&Data, const uchar *L
} }
Data = Limit; Data = Limit;
unsigned long *Scanner = (unsigned long *)(Data - 3); uint32_t *Scanner = (uint32_t *)(Data - 3);
scanner = ntohl(*Scanner); scanner = ntohl(*Scanner);
return false; return false;
} }
@ -615,7 +615,7 @@ bool cVideoRepacker::ScanForEndOfPictureFast(const uchar *&Data, const uchar *Li
} }
Data = Limit + 1; Data = Limit + 1;
unsigned long *LocalScanner = (unsigned long *)(Data - 4); uint32_t *LocalScanner = (uint32_t *)(Data - 4);
localScanner = ntohl(*LocalScanner); localScanner = ntohl(*LocalScanner);
return false; return false;
} }

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: skins.c 1.11 2006/06/03 14:39:14 kls Exp $ * $Id: skins.c 1.12 2006/12/01 13:32:37 kls Exp $
*/ */
#include "skins.h" #include "skins.h"
@ -226,8 +226,11 @@ eKeys cSkins::Message(eMessageType Type, const char *s, int Seconds)
} }
if (!Current()) if (!Current())
return kNone; return kNone;
if (!cSkinDisplay::Current() && !displayMessage) if (!cSkinDisplay::Current()) {
if (displayMessage)
delete displayMessage;
displayMessage = Current()->DisplayMessage(); displayMessage = Current()->DisplayMessage();
}
cSkinDisplay::Current()->SetMessage(Type, s); cSkinDisplay::Current()->SetMessage(Type, s);
cSkinDisplay::Current()->Flush(); cSkinDisplay::Current()->Flush();
cStatus::MsgOsdStatusMessage(s); cStatus::MsgOsdStatusMessage(s);

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: tools.c 1.120 2006/08/12 13:30:07 kls Exp $ * $Id: tools.c 1.121 2006/12/02 11:12:59 kls Exp $
*/ */
#include "tools.h" #include "tools.h"
@ -547,11 +547,11 @@ cTimeMs::cTimeMs(void)
Set(); Set();
} }
uint64 cTimeMs::Now(void) uint64_t cTimeMs::Now(void)
{ {
struct timeval t; struct timeval t;
if (gettimeofday(&t, NULL) == 0) if (gettimeofday(&t, NULL) == 0)
return (uint64(t.tv_sec)) * 1000 + t.tv_usec / 1000; return (uint64_t(t.tv_sec)) * 1000 + t.tv_usec / 1000;
return 0; return 0;
} }
@ -565,7 +565,7 @@ bool cTimeMs::TimedOut(void)
return Now() >= begin; return Now() >= begin;
} }
uint64 cTimeMs::Elapsed(void) uint64_t cTimeMs::Elapsed(void)
{ {
return Now() - begin; return Now() - begin;
} }

10
tools.h
View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: tools.h 1.93 2006/04/16 10:40:45 kls Exp $ * $Id: tools.h 1.94 2006/12/02 11:14:14 kls Exp $
*/ */
#ifndef __TOOLS_H #ifndef __TOOLS_H
@ -15,6 +15,7 @@
#include <fcntl.h> #include <fcntl.h>
#include <poll.h> #include <poll.h>
#include <stddef.h> #include <stddef.h>
#include <stdint.h>
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>
#include <syslog.h> #include <syslog.h>
@ -22,7 +23,6 @@
#include <sys/types.h> #include <sys/types.h>
typedef unsigned char uchar; typedef unsigned char uchar;
typedef unsigned long long int uint64;
extern int SysLogLevel; extern int SysLogLevel;
@ -159,13 +159,13 @@ public:
class cTimeMs { class cTimeMs {
private: private:
uint64 begin; uint64_t begin;
public: public:
cTimeMs(void); cTimeMs(void);
static uint64 Now(void); static uint64_t Now(void);
void Set(int Ms = 0); void Set(int Ms = 0);
bool TimedOut(void); bool TimedOut(void);
uint64 Elapsed(void); uint64_t Elapsed(void);
}; };
class cReadLine { class cReadLine {

14
vdr.1
View File

@ -8,7 +8,7 @@
.\" License as specified in the file COPYING that comes with the .\" License as specified in the file COPYING that comes with the
.\" vdr distribution. .\" vdr distribution.
.\" .\"
.\" $Id: vdr.1 1.26 2006/06/24 10:07:16 kls Exp $ .\" $Id: vdr.1 1.27 2006/11/19 10:02:31 kls Exp $
.\" .\"
.TH vdr 1 "30 Apr 2006" "1.4.0" "Video Disk Recorder" .TH vdr 1 "30 Apr 2006" "1.4.0" "Video Disk Recorder"
.SH NAME .SH NAME
@ -23,12 +23,12 @@ It can work with signals received from satellites (DVB-S) as
well as cable (DVB-C) and terrestrial (DVB-T) signals. well as cable (DVB-C) and terrestrial (DVB-T) signals.
At least one DVB card is required to run \fBvdr\fR. With it you can watch At least one DVB card is required to run \fBvdr\fR. With it you can watch
live tv while recording one or more other broadcasts from the same transponder. live TV while recording one or more other broadcasts from the same transponder.
It is also possible to start watching a recorded programme before the live It is also possible to start watching a recorded programme before the live
broadcast has ended (\fBtime shifting\fR). In order to record from different broadcast has ended (\fBtime shifting\fR). In order to record from different
transponders simultaneously two or more DVB cards are necessary. transponders simultaneously two or more DVB cards are necessary.
By default \fBvdr\fR can support up to four By default \fBvdr\fR can support up to four
DVB cards. The primary DVB card (the one your tv set is connected to) has DVB cards. The primary DVB card (the one your TV set is connected to) has
to be a "full featured" card, which means it must contain an MPEG decoder to be a "full featured" card, which means it must contain an MPEG decoder
and provide audio and video signal outputs. and provide audio and video signal outputs.
@ -76,7 +76,7 @@ Set logging to \fIlevel\fR.
\fB0\fR\ =\ no logging, \fB1\fR\ =\ errors only, \fB0\fR\ =\ no logging, \fB1\fR\ =\ errors only,
\fB2\fR\ =\ errors and info, \fB3\fR\ =\ errors, info and debug. \fB2\fR\ =\ errors and info, \fB3\fR\ =\ errors, info and debug.
The default logging level is \fB3\fR. The default logging level is \fB3\fR.
If logging should be done to LOG_LOCALn instead of If logging should be done to LOG_LOCAL\fIn\fR instead of
LOG_USER, add '.n' to LEVEL, as in 3.7 (n=0..7). LOG_USER, add '.n' to LEVEL, as in 3.7 (n=0..7).
.TP .TP
.BI \-L\ dir ,\ \-\-lib= dir .BI \-L\ dir ,\ \-\-lib= dir
@ -122,10 +122,12 @@ Use a serial port remote control device.
If \fIpath\fR is omitted, vdr uses \fI/dev/ttyS1\fR. If \fIpath\fR is omitted, vdr uses \fI/dev/ttyS1\fR.
.TP .TP
.BI \-r\ cmd ,\ \-\-record= cmd .BI \-r\ cmd ,\ \-\-record= cmd
Call \fIcmd\fR before and after a recording. Call \fIcmd\fR before and after a recording. See the file \fIINSTALL\fR for
more information.
.TP .TP
.BI \-s\ cmd ,\ \-\-shutdown= cmd .BI \-s\ cmd ,\ \-\-shutdown= cmd
Call \fIcmd\fR to shutdown the computer. Call \fIcmd\fR to shutdown the computer. See the file \fIINSTALL\fR for more
information.
.TP .TP
.BI \-t\ tty ,\ \-\-terminal= tty .BI \-t\ tty ,\ \-\-terminal= tty
Set the controlling terminal. Set the controlling terminal.

8
vdr.5
View File

@ -8,7 +8,7 @@
.\" License as specified in the file COPYING that comes with the .\" License as specified in the file COPYING that comes with the
.\" vdr distribution. .\" vdr distribution.
.\" .\"
.\" $Id: vdr.5 1.59 2006/04/30 08:55:16 kls Exp $ .\" $Id: vdr.5 1.60 2006/11/19 10:02:33 kls Exp $
.\" .\"
.TH vdr 5 "30 Apr 2006" "1.4.0" "Video Disk Recorder Files" .TH vdr 5 "30 Apr 2006" "1.4.0" "Video Disk Recorder Files"
.SH NAME .SH NAME
@ -57,7 +57,7 @@ to right):
.B Name .B Name
The channel's name (if the name originally contains a ':' character The channel's name (if the name originally contains a ':' character
it has to be replaced by '|'). it has to be replaced by '|').
Some tv stations provide a way of deriving a "short name" from the Some TV stations provide a way of deriving a "short name" from the
channel name, which can be used in situations where there is not channel name, which can be used in situations where there is not
much space for displaying a long name. If a short name is available much space for displaying a long name. If a short name is available
for this channel, it follows the full name and is delimited by a comma, for this channel, it follows the full name and is delimited by a comma,
@ -248,7 +248,7 @@ cause the timer to record on that day. Example:
.B MTWTF\-\- .B MTWTF\-\-
will define a timer that records on Monday thru Friday and does not record will define a timer that records on Monday through Friday and does not record
on weekends. The same result could be achieved with \fBABCDE\-\-\fR (this is on weekends. The same result could be achieved with \fBABCDE\-\-\fR (this is
used to allow setting the days with language specific characters). used to allow setting the days with language specific characters).
Note that only letters may be used here, no digits. Note that only letters may be used here, no digits.
@ -259,7 +259,7 @@ so a complete definition could look like this:
\fBMTWTF\-\-@2002\-02\-18\fR \fBMTWTF\-\-@2002\-02\-18\fR
which would implement a timer that records Monday thru Friday, and will hit which would implement a timer that records Monday through Friday, and will hit
for the first time on or after February 18, 2002. for the first time on or after February 18, 2002.
This \fBfirst day\fR feature can be used to disable a repeating timer for a couple This \fBfirst day\fR feature can be used to disable a repeating timer for a couple
of days, or for instance to define a new Mon...Fri timer on Wednesday, which of days, or for instance to define a new Mon...Fri timer on Wednesday, which

8
vdr.c
View File

@ -22,7 +22,7 @@
* *
* The project's page is at http://www.cadsoft.de/vdr * The project's page is at http://www.cadsoft.de/vdr
* *
* $Id: vdr.c 1.280 2006/10/14 10:01:32 kls Exp $ * $Id: vdr.c 1.282 2006/12/02 16:22:12 kls Exp $
*/ */
#include <getopt.h> #include <getopt.h>
@ -1154,7 +1154,7 @@ int main(int argc, char *argv[])
Skins.Message(mtInfo, tr("Editing process finished")); Skins.Message(mtInfo, tr("Editing process finished"));
} }
} }
if (!Interact && ((!cRecordControls::Active() && !cCutter::Active() && !cPluginManager::Active() && (!Interface->HasSVDRPConnection() || UserShutdown)) || ForceShutdown)) { if (!Interact && ((!cRecordControls::Active() && !cCutter::Active() && (!Interface->HasSVDRPConnection() || UserShutdown)) || ForceShutdown)) {
time_t Now = time(NULL); time_t Now = time(NULL);
if (Now - LastActivity > ACTIVITYTIMEOUT) { if (Now - LastActivity > ACTIVITYTIMEOUT) {
// Shutdown: // Shutdown:
@ -1178,6 +1178,10 @@ int main(int argc, char *argv[])
timer = NULL; timer = NULL;
dsyslog("reboot at %s", *TimeToString(Next)); dsyslog("reboot at %s", *TimeToString(Next));
} }
if (!ForceShutdown && cPluginManager::Active()) {
LastActivity = Now - Setup.MinUserInactivity * 60 + SHUTDOWNRETRY; // try again later
continue;
}
if (!Next || Delta > Setup.MinEventTimeout * 60 || ForceShutdown) { if (!Next || Delta > Setup.MinEventTimeout * 60 || ForceShutdown) {
ForceShutdown = false; ForceShutdown = false;
if (timer) if (timer)