Commit Graph

5 Commits

Author SHA1 Message Date
Michael Kerrisk 63aa9df02f Automated unformatting of parentheses using unformat_parens.sh 2005-10-19 07:07:02 +00:00
Michael Kerrisk 84a0a0510d Remove misleading text describing FreeBSD's sranddev() function.
As per debian bug 328629
2005-09-21 11:23:38 +00:00
Michael Kerrisk b14d4aa5b8 Classical BSD versions are now always named x.yBSD (formerly
there was a mix of x.yBSD and BSD x.y).
2005-07-18 15:05:56 +00:00
Michael Kerrisk 6e657687f9 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=194842
Because RAND_MAX is equal to INT_MAX, the following expression
contained in the manpage for rand(3) is slightly incorrect.
j=1+(int) (10.0*rand()/(RAND_MAX+1.0));

The correct expression should use parentheses to group the division
before the multiplication, thus yielding:
j=1+(int) (10.0*(rand()/(RAND_MAX+1.0)));

This is not an error where 10.0 is a floating point number, however
where 10.0 is replaced with an integer, this will cause the expression
to always evaluate to 1. (The addition of two parentheses would make
this bug a lot more difficult to make.)
2005-06-21 09:22:02 +00:00
Michael Kerrisk fea681dafb Import of man-pages 1.70 2004-11-03 13:51:07 +00:00