-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
The pyorient unit test test_binary_date (tests.test_serializations.SerializationTestCase) is failing. The returned date for me is a day off.
I narrowed this down to the mktime/gmtime pair in encoding/decoding. mktime expects a local time and gmtime() a UTC time.
Supposedly it's not portable, but I wrote a little test program, and adding this to the structure passed to mktime seems to work better:
t.tm_isdst = -1;
time_t now = time(0);
t.tm_sec += difftime(now, 0) - difftime(mktime(gmtime(&now)), 0);Metadata
Metadata
Assignees
Labels
No labels