]> git.pond.sub.org Git - empserver/commitdiff
(empth_sleep) [_WIN32]: Remove a change to the random seeding
authorRon Koenderink <rkoenderink@yahoo.ca>
Sat, 20 Oct 2007 12:15:45 +0000 (12:15 +0000)
committerRon Koenderink <rkoenderink@yahoo.ca>
Sat, 20 Oct 2007 12:15:45 +0000 (12:15 +0000)
that accidently got committed in rev 1.65.

src/lib/empthread/ntthread.c

index 5c6dbe71484495976523d7409fe05be81fe800bf..73a2cecc51c1e2a9678423399a1adb6acadec6a4 100644 (file)
@@ -326,6 +326,8 @@ loc_Exit_Handler(DWORD fdwCtrlType)
 static void
 empth_threadMain(void *pvData)
 {
+    time_t now;
+
     empth_t *pThread = pvData;
 
     /* Out of here... */
@@ -345,10 +347,8 @@ empth_threadMain(void *pvData)
      * seed the rand() function
      * In WIN32, each thread has seed
      */
-    if (rnd_seed.set)
-       srand(rnd_seed.seed);
-    else
-       srand(time(NULL) ^ (unsigned)pThread);
+    time(&now);
+    srand( ^ (unsigned)pThread);
 
     /* Switch to this thread context */
     loc_RunThisThread(NULL);