diff options
author | phk <phk@FreeBSD.org> | 1998-04-06 11:40:42 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1998-04-06 11:40:42 +0000 |
commit | 4b6dfe92bd78164a8094e9abc6d8947f2eb64c90 (patch) | |
tree | cb4a3575dde7e33e9a1a45abd4992f334ef49211 /sys/contrib | |
parent | 1e2405b5f18aa2ed474f99f12fc3d7a044a491cd (diff) | |
download | FreeBSD-src-4b6dfe92bd78164a8094e9abc6d8947f2eb64c90.zip FreeBSD-src-4b6dfe92bd78164a8094e9abc6d8947f2eb64c90.tar.gz |
Use read_random()
Diffstat (limited to 'sys/contrib')
-rw-r--r-- | sys/contrib/ipfilter/netinet/ip_log.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/contrib/ipfilter/netinet/ip_log.c b/sys/contrib/ipfilter/netinet/ip_log.c index 889cf5d..2d78915 100644 --- a/sys/contrib/ipfilter/netinet/ip_log.c +++ b/sys/contrib/ipfilter/netinet/ip_log.c @@ -5,7 +5,7 @@ * provided that this notice is preserved and due credit is given * to the original author and the contributors. * - * $Id: ip_log.c,v 1.2 1998/03/21 11:34:14 peter Exp $ + * $Id: ip_log.c,v 1.3 1998/03/21 14:42:45 peter Exp $ */ #include "opt_ipfilter.h" @@ -76,6 +76,7 @@ # endif # if __FreeBSD_version >= 300000 # include <sys/malloc.h> +# include <machine/random.h> # endif # include <net/route.h> # include <netinet/in.h> @@ -142,12 +143,16 @@ void ipflog_init() iplh[i] = &iplt[i]; iplused[i] = 0; } -# if BSD >= 199306 || defined(__FreeBSD__) || defined(__sgi) +# if defined(__FreeBSD__) && __FreeBSD_version >= 300000 + read_random(&iplcrcinit, sizeof iplcrcinit); +# else +#if BSD >= 199306 || defined(__FreeBSD__) || defined(__sgi) microtime(&tv); # else uniqtime(&tv); # endif iplcrcinit = tv.tv_sec ^ (tv.tv_usec << 8) ^ tv.tv_usec; +# endif } |