"Zebediah Figura (she/her)" zfigura@codeweavers.com writes:
On 8/24/21 1:03 PM, Alexandre Julliard wrote:
Zebediah Figura zfigura@codeweavers.com writes:
@@ -410,6 +410,16 @@ static void atomic_store_long(volatile LONG *ptr, LONG value) static void set_user_shared_data_time(void) { timeout_t tick_count = monotonic_time / 10000;
- timeout_t timezone_bias;
- struct tm *tm;
- time_t now;
- now = time( NULL );
- tm = gmtime( &now );
- timezone_bias = mktime( tm ) - now;
- tm = localtime( &now );
- if (tm->tm_isdst) timezone_bias -= 3600;
- timezone_bias *= TICKS_PER_SEC;
Do we really want to do that on every request?
Presumably it can change whenever the user changes the time zone (or, more realistically, if DST happens to flip over). I'm not aware of a better way to detect that, and I didn't think we'd want to ignore changes. I guess we could always cache it for some fixed length of time, though it's not clear to me that's not a bad idea either.
At least it doesn't seem useful to update this more than once per second.