Differences From Artifact [d7cb394675]:
- File
src/OFDate.m
— part of check-in
[f1765412c7]
at
2016-02-22 15:25:43
on branch trunk
— OFDate: Do not use lrint() for microseconds
It's better to make sure we never round up, as it's better to be a
little bit behind in time than ahead.This has the nice side effect of fixing the test on the 3DS, as lrint()
is behaving differently there. (user: js, size: 13690) [annotate] [blame] [check-ins using]
To Artifact [7b98bd3de0]:
- File src/OFDate.m — part of check-in [7d381048fb] at 2016-05-21 22:19:59 on branch trunk — OFDate: Use _mktime64() on Windows (user: js, size: 13811) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 | tm.tm_isdst = -1; if (of_strptime([string UTF8String], [format UTF8String], &tm) == NULL) @throw [OFInvalidFormatException exception]; if ((_seconds = mktime(&tm)) == -1) @throw [OFInvalidFormatException exception]; } @catch (id e) { [self release]; @throw e; } return self; } | > > > > > | 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 | tm.tm_isdst = -1; if (of_strptime([string UTF8String], [format UTF8String], &tm) == NULL) @throw [OFInvalidFormatException exception]; #ifndef OF_WINDOWS if ((_seconds = mktime(&tm)) == -1) @throw [OFInvalidFormatException exception]; #else if ((_seconds = _mktime64(&tm)) == -1) @throw [OFInvalidFormatException exception]; #endif } @catch (id e) { [self release]; @throw e; } return self; } |
︙ | ︙ |