Make GoldED+ behave well with DST. Change in CfgFormat patch.

This commit is contained in:
Jacobo Tarrío
2000-10-06 23:16:09 +00:00
parent 324ac58736
commit a139901f24
11 changed files with 50 additions and 14 deletions

View File

@@ -361,7 +361,9 @@ time_t FTimeToTime(FTime* __ftime, struct tm* __tm) {
__tm->tm_isdst = -1;
time_t a = mktime(__tm);
time_t b = mktime(gmtime(&a));
struct tm *tp = gmtime(&a);
tp->tm_isdst = -1;
time_t b = mktime(tp);
_time = a + a - b;
if(_time == (ulong)0xFFFFFFFFL)
@@ -450,7 +452,9 @@ time_t FidoTimeToUnix(char* ptr) {
t.tm_sec = second;
t.tm_isdst = -1;
time_t a = mktime(&t);
time_t b = mktime(gmtime(&a));
struct tm *tp = gmtime(&a);
tp->tm_isdst = -1;
time_t b = mktime(tp);
return a + a - b;
}
return (ulong)-1;