1
0
mirror of https://github.com/VDR4Arch/vdr.git synced 2023-10-10 13:36:52 +02:00

cTimeMs is no longer initialized to the current time if the value given to the constructor is negative

This commit is contained in:
Klaus Schmidinger 2011-08-15 14:13:42 +02:00
parent 4a9fd9b097
commit f4007c7ff3
4 changed files with 13 additions and 5 deletions

View File

@ -6695,3 +6695,6 @@ Video Disk Recorder Revision History
can be used together with --edit to set the maximum video file size and turn on
splitting edited files at the editing marks. These options must be given before
--edit to have an effect.
- cTimeMs is no longer initialized to the current time if the value given to the
constructor is negative (avoids the "cTimeMs: using monotonic clock..." log message
before VDR's starting log message).

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: remote.c 2.3 2011/03/27 15:03:36 kls Exp $
* $Id: remote.c 2.4 2011/08/15 13:41:40 kls Exp $
*/
#include "remote.h"
@ -26,7 +26,7 @@
eKeys cRemote::keys[MaxKeys];
int cRemote::in = 0;
int cRemote::out = 0;
cTimeMs cRemote::repeatTimeout;
cTimeMs cRemote::repeatTimeout(-1);
cRemote *cRemote::learning = NULL;
char *cRemote::unknownCode = NULL;
cMutex cRemote::mutex;

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: tools.c 2.16 2011/08/15 12:23:20 kls Exp $
* $Id: tools.c 2.17 2011/08/15 13:35:23 kls Exp $
*/
#include "tools.h"
@ -571,7 +571,10 @@ time_t LastModifiedTime(const char *FileName)
cTimeMs::cTimeMs(int Ms)
{
if (Ms >= 0)
Set(Ms);
else
begin = 0;
}
uint64_t cTimeMs::Now(void)

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: tools.h 2.10 2011/08/15 11:50:02 kls Exp $
* $Id: tools.h 2.11 2011/08/15 14:13:42 kls Exp $
*/
#ifndef __TOOLS_H
@ -272,6 +272,8 @@ private:
public:
cTimeMs(int Ms = 0);
///< Creates a timer with ms resolution and an initial timeout of Ms.
///< If Ms is negative the timer is not initialized with the current
///< time.
static uint64_t Now(void);
void Set(int Ms = 0);
bool TimedOut(void);