mirror of
https://github.com/fluencelabs/redis
synced 2025-07-02 10:21:32 +00:00
Cache timezone and daylight active flag for safer logging.
With such information will be able to use a private localtime() implementation serverLog(), which does not use any locking and is both thread and fork() safe.
This commit is contained in:
@ -1192,6 +1192,8 @@ struct redisServer {
|
||||
int list_compress_depth;
|
||||
/* time cache */
|
||||
time_t unixtime; /* Unix time sampled every cron cycle. */
|
||||
time_t timezone; /* Cached timezone. As set by tzset(). */
|
||||
int daylight_active; /* Currently in daylight saving time. */
|
||||
long long mstime; /* Like 'unixtime' but with milliseconds resolution. */
|
||||
/* Pubsub */
|
||||
dict *pubsub_channels; /* Map channels to list of subscribed clients */
|
||||
|
Reference in New Issue
Block a user