mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-22 16:18:28 -05:00
Set the initial seed for random() (#5679)
This commit is contained in:
parent
2530dc0ebd
commit
47637bea6d
@ -5135,6 +5135,7 @@ int main(int argc, char **argv) {
|
||||
tzset(); /* Populates 'timezone' global. */
|
||||
zmalloc_set_oom_handler(redisOutOfMemoryHandler);
|
||||
srand(time(NULL)^getpid());
|
||||
srandom(time(NULL)^getpid());
|
||||
gettimeofday(&tv,NULL);
|
||||
crc64_init();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user