Re: svn commit: r300384 - head/sys/compat/ndis

2016-05-21 Thread Pedro Giffuni
> Il giorno 21/mag/2016, alle ore 21:15, Bruce Evans ha > scritto: > > On Sun, 22 May 2016, Pedro F. Giffuni wrote: > >> Log: >> ndis(4): adjustments for our random() specific implementation. >> >> - Revert r300377: The implementation claims to return a value >> within the range. [1] >> -

Re: svn commit: r300384 - head/sys/compat/ndis

2016-05-21 Thread Andrey Chernov
On 22.05.2016 3:29, Pedro F. Giffuni wrote: > static void > srand(unsigned int seed) > { > > + if (seed == 0) > + seed = 1; > srandom(seed); > } IMHO it is not needed. srandom() already handles seed == 0 case, there is no point to remap it to another constant. _

Re: svn commit: r300384 - head/sys/compat/ndis

2016-05-21 Thread Bruce Evans
On Sun, 22 May 2016, Pedro F. Giffuni wrote: Log: ndis(4): adjustments for our random() specific implementation. - Revert r300377: The implementation claims to return a value within the range. [1] - Adjust the value for the case of a zero seed, whihc according to standards should be e

svn commit: r300384 - head/sys/compat/ndis

2016-05-21 Thread Pedro F. Giffuni
Author: pfg Date: Sun May 22 00:29:25 2016 New Revision: 300384 URL: https://svnweb.freebsd.org/changeset/base/300384 Log: ndis(4): adjustments for our random() specific implementation. - Revert r300377: The implementation claims to return a value within the range. [1] - Adjust the v