mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Fixed a problem with Daylight Saving Time
This commit is contained in:
parent
a270907cf5
commit
5d997d4622
2
HISTORY
2
HISTORY
@ -432,3 +432,5 @@ Video Disk Recorder Revision History
|
|||||||
- Fixed setting system time from transponders.
|
- Fixed setting system time from transponders.
|
||||||
- Fixed a segfault in the Schedule menu in case there is no EPG information.
|
- Fixed a segfault in the Schedule menu in case there is no EPG information.
|
||||||
- The 'runvdr' script now kills any leftover vdr threads before restarting it.
|
- The 'runvdr' script now kills any leftover vdr threads before restarting it.
|
||||||
|
- Fixed a problem with Daylight Saving Time when displaying the times of
|
||||||
|
recordings.
|
||||||
|
@ -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.c 1.28 2001/02/18 16:14:05 kls Exp $
|
* $Id: recording.c 1.29 2001/03/31 09:38:30 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define _GNU_SOURCE
|
#define _GNU_SOURCE
|
||||||
@ -206,6 +206,7 @@ cRecording::cRecording(const char *FileName)
|
|||||||
if (p) {
|
if (p) {
|
||||||
time_t now = time(NULL);
|
time_t now = time(NULL);
|
||||||
struct tm t = *localtime(&now); // this initializes the time zone in 't'
|
struct tm t = *localtime(&now); // this initializes the time zone in 't'
|
||||||
|
t.tm_isdst = -1; // makes sure mktime() will determine the correct dst setting
|
||||||
if (7 == sscanf(p + 1, DATAFORMAT, &t.tm_year, &t.tm_mon, &t.tm_mday, &t.tm_hour, &t.tm_min, &priority, &lifetime)) {
|
if (7 == sscanf(p + 1, DATAFORMAT, &t.tm_year, &t.tm_mon, &t.tm_mday, &t.tm_hour, &t.tm_min, &priority, &lifetime)) {
|
||||||
t.tm_year -= 1900;
|
t.tm_year -= 1900;
|
||||||
t.tm_mon--;
|
t.tm_mon--;
|
||||||
|
Loading…
Reference in New Issue
Block a user