Skip to content
Snippets Groups Projects
Commit c2ab921e authored by rswindell's avatar rswindell
Browse files

Seed random number generator with ticks instead of seconds and through away

first result.
parent 4c2c2d64
Branches
Tags
No related merge requests found
......@@ -4310,7 +4310,8 @@ void DLLCALL ftp_server(void* arg)
lprintf("Compiled %s %s with %s", __DATE__, __TIME__, compiler);
srand(time(NULL));
srand(clock()); /* Seed random number generator */
sbbs_random(10); /* Throw away first number */
if(!(startup->options&FTP_OPT_LOCAL_TIMEZONE)) {
if(PUTENV("TZ=UTC0"))
......
......@@ -1030,7 +1030,8 @@ void DLLCALL services_thread(void* arg)
lprintf("Compiled %s %s with %s", __DATE__, __TIME__, compiler);
srand(time(NULL));
srand(clock()); /* Seed random number generator */
sbbs_random(10); /* Throw away first number */
if(!(startup->options&BBS_OPT_LOCAL_TIMEZONE)) {
if(PUTENV("TZ=UTC0"))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment