Module Name:    src
Committed By:   dholland
Date:           Mon May 25 23:41:23 UTC 2009

Modified Files:
        src/games/mille: mille.c

Log Message:
Use the time to call srandom(), not getpid().


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/games/mille/mille.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/games/mille/mille.c
diff -u src/games/mille/mille.c:1.18 src/games/mille/mille.c:1.19
--- src/games/mille/mille.c:1.18	Mon May 25 23:34:50 2009
+++ src/games/mille/mille.c	Mon May 25 23:41:23 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: mille.c,v 1.18 2009/05/25 23:34:50 dholland Exp $	*/
+/*	$NetBSD: mille.c,v 1.19 2009/05/25 23:41:23 dholland Exp $	*/
 
 /*
  * Copyright (c) 1982, 1993
@@ -39,10 +39,11 @@
 #if 0
 static char sccsid[] = "@(#)mille.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: mille.c,v 1.18 2009/05/25 23:34:50 dholland Exp $");
+__RCSID("$NetBSD: mille.c,v 1.19 2009/05/25 23:41:23 dholland Exp $");
 #endif
 #endif /* not lint */
 
+#include <time.h>
 #include "mille.h"
 #include <signal.h>
 
@@ -91,7 +92,7 @@
 	leaveok(Miles, TRUE);
 	clearok(curscr, TRUE);
 #ifndef PROF
-	srandom(getpid());
+	srandom((long) time(NULL));
 #else
 	srandom(0);
 #endif

Reply via email to