svn commit: r187571 - projects/stress2/lib
Peter Holm
pho at freebsd.org
Thu Jan 22 01:11:27 PST 2009
On Thu, Jan 22, 2009 at 09:56:16AM +0100, Roman Divacky wrote:
> On Thu, Jan 22, 2009 at 07:59:08AM +0100, Peter Holm wrote:
> > On Wed, Jan 21, 2009 at 11:12:58PM +0100, Roman Divacky wrote:
> > > On Wed, Jan 21, 2009 at 09:24:36PM +0000, Peter Holm wrote:
> > > > Author: pho
> > > > Date: Wed Jan 21 21:24:36 2009
> > > > New Revision: 187571
> > > > URL: http://svn.freebsd.org/changeset/base/187571
> > > >
> > > > Log:
> > > > Attempt to ensure that setup() is called before any system load.
> > > >
> > > > Approved by: kib
> > > >
> > > > Modified:
> > > > projects/stress2/lib/main.c
> > > >
> > > > Modified: projects/stress2/lib/main.c
> > > > ==============================================================================
> > > > --- projects/stress2/lib/main.c Wed Jan 21 21:01:02 2009 (r187570)
> > > > +++ projects/stress2/lib/main.c Wed Jan 21 21:24:36 2009 (r187571)
> > > > @@ -106,10 +106,9 @@ run_tests(int i)
> > > > signal(SIGHUP, run_test_handler);
> > > > signal(SIGINT, exit_handler);
> > > > atexit(callcleanup);
> > > > - arc4random_stir();
> > > > + setup(i);
> > > > if ((strcmp(getprogname(), "run") != 0) && (op->nodelay == 0))
> > > > sleep(random_int(1,10));
> > > > - setup(i);
> > > > start = time(NULL);
> > > > while (done_testing == 0 &&
> > > > (time(NULL) - start) < op->run_time) {
> > >
> > > are you sure you want to get rid of the arc4random_stir() ?
> >
> > No, but to quote the man page:
> >
> > There is no need to call arc4random_stir() before using arc4random(),
> > since arc4random() automatically initializes itself.
> >
> > Is that wrong?
>
> no :) but it wasnt mentioned in the commit message so I guessed
> it might have been a mistake
Good point. Thanx :-)
- Peter
More information about the svn-src-projects
mailing list