Date: Sat, 23 Jul 2005 05:55:17 +0400 From: Andrey Chernov <ache@FreeBSD.ORG> To: Greg Lehey <grog@FreeBSD.ORG> Cc: cvs-src@FreeBSD.ORG, src-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/games/fortune/fortune fortune.c Message-ID: <20050723015517.GA28428@nagual.pp.ru> In-Reply-To: <200507230146.j6N1koqL061690@repoman.freebsd.org> References: <200507230146.j6N1koqL061690@repoman.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Jul 23, 2005 at 01:46:50AM +0000, Greg Lehey wrote: > grog 2005-07-23 01:46:50 UTC > > FreeBSD src repository > > Modified files: > games/fortune/fortune fortune.c > Log: > Use a random number to seed the random number generator. Goodby, Rush > Limbaugh. > > This should have already worked properly if random(4) has been > initialized correctly, but it seems that this is frequently not the > case. Instead, use the microsecond part of the current time as the > seed. It is already properly and truly randomly initialized, instead of any microseconds tricks. Do you miss srandomdev(); here? -- http://ache.pp.ru/
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050723015517.GA28428>