summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--primes/primes.c7
-rw-r--r--quiz/quiz.c11
-rw-r--r--random/random.c13
-rw-r--r--rogue/USD.doc/rogue.me5
4 files changed, 21 insertions, 15 deletions
diff --git a/primes/primes.c b/primes/primes.c
index 868d994f..1390e66a 100644
--- a/primes/primes.c
+++ b/primes/primes.c
@@ -1,4 +1,4 @@
-/* $NetBSD: primes.c,v 1.5 1995/04/24 12:24:47 cgd Exp $ */
+/* $NetBSD: primes.c,v 1.6 1997/01/07 12:24:57 tls Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -44,9 +44,9 @@ static char copyright[] =
#ifndef lint
#if 0
-static char sccsid[] = "@(#)primes.c 8.4 (Berkeley) 3/21/94";
+static char sccsid[] = "@(#)primes.c 8.5 (Berkeley) 5/10/95";
#else
-static char rcsid[] = "$NetBSD: primes.c,v 1.5 1995/04/24 12:24:47 cgd Exp $";
+static char rcsid[] = "$NetBSD: primes.c,v 1.6 1997/01/07 12:24:57 tls Exp $";
#endif
#endif /* not lint */
@@ -75,6 +75,7 @@ static char rcsid[] = "$NetBSD: primes.c,v 1.5 1995/04/24 12:24:47 cgd Exp $";
#include <memory.h>
#include <stdio.h>
#include <stdlib.h>
+#include <unistd.h>
#include "primes.h"
diff --git a/quiz/quiz.c b/quiz/quiz.c
index 6af648d2..60a89264 100644
--- a/quiz/quiz.c
+++ b/quiz/quiz.c
@@ -1,4 +1,4 @@
-/* $NetBSD: quiz.c,v 1.9 1995/04/22 10:16:58 cgd Exp $ */
+/* $NetBSD: quiz.c,v 1.10 1997/01/07 12:27:30 tls Exp $ */
/*-
* Copyright (c) 1991, 1993
@@ -45,20 +45,23 @@ static char copyright[] =
#ifndef lint
#if 0
-static char sccsid[] = "@(#)quiz.c 8.2 (Berkeley) 1/3/94";
+static char sccsid[] = "@(#)quiz.c 8.3 (Berkeley) 5/4/95";
#else
-static char rcsid[] = "$NetBSD: quiz.c,v 1.9 1995/04/22 10:16:58 cgd Exp $";
+static char rcsid[] = "$NetBSD: quiz.c,v 1.10 1997/01/07 12:27:30 tls Exp $";
#endif
#endif /* not lint */
#include <sys/types.h>
+
+#include <ctype.h>
#include <errno.h>
-#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <err.h>
+#include <time.h>
+#include <unistd.h>
#include "quiz.h"
#include "pathnames.h"
diff --git a/random/random.c b/random/random.c
index 96267e25..f48ecbbb 100644
--- a/random/random.c
+++ b/random/random.c
@@ -1,4 +1,4 @@
-/* $NetBSD: random.c,v 1.3 1995/04/22 07:44:05 cgd Exp $ */
+/* $NetBSD: random.c,v 1.4 1997/01/07 12:30:26 tls Exp $ */
/*
* Copyright (c) 1994
@@ -44,13 +44,14 @@ static char copyright[] =
#ifndef lint
#if 0
-static char sccsid[] = "@(#)random.c 8.5 (Berkeley) 4/5/94";
+static char sccsid[] = "@(#)random.c 8.6 (Berkeley) 6/1/94";
#else
-static char rcsid[] = "$NetBSD: random.c,v 1.3 1995/04/22 07:44:05 cgd Exp $";
+static char rcsid[] = "$NetBSD: random.c,v 1.4 1997/01/07 12:30:26 tls Exp $";
#endif
#endif /* not lint */
#include <sys/types.h>
+#include <sys/time.h>
#include <err.h>
#include <errno.h>
@@ -68,7 +69,7 @@ main(argc, argv)
char *argv[];
{
extern int optind;
- time_t now;
+ struct timeval tp;
double denom;
int ch, random_exit, selected, unbuffer_output;
char *ep;
@@ -108,8 +109,8 @@ main(argc, argv)
/* NOTREACHED */
}
- (void)time(&now);
- srandom((u_int)(now + getpid()));
+ (void)gettimeofday(&tp, NULL);
+ srandom((u_int)(tp.tv_usec + tp.tv_sec + getpid()));
/* Compute a random exit status between 0 and denom - 1. */
if (random_exit)
diff --git a/rogue/USD.doc/rogue.me b/rogue/USD.doc/rogue.me
index 749648de..4c122161 100644
--- a/rogue/USD.doc/rogue.me
+++ b/rogue/USD.doc/rogue.me
@@ -1,4 +1,4 @@
-.\" $NetBSD: rogue.me,v 1.2 1995/04/22 10:28:50 cgd Exp $
+.\" $NetBSD: rogue.me,v 1.3 1997/01/07 12:31:57 tls Exp $
.\"
.\" Copyright (c) 1986, 1993
.\" The Regents of the University of California. All rights reserved.
@@ -31,7 +31,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" @(#)rogue.me 8.1 (Berkeley) 6/8/93
+.\" @(#)rogue.me 8.2 (Berkeley) 6/1/94
.\"
.ds E \s-2<ESCAPE>\s0
.ds R \s-2<RETURN>\s0
@@ -665,6 +665,7 @@ Due to variations in personal tastes
and conceptions of the way rogue should do things,
there are a set of options you can set
that cause rogue to behave in various different ways.
+.ne 1i
.sh 2 "Setting the options"
.pp
There are two ways to set the options.