aboutsummaryrefslogtreecommitdiffstats
path: root/man3
diff options
context:
space:
mode:
authorMichael Kerrisk <mtk.manpages@gmail.com>2010-09-12 16:29:06 +0200
committerMichael Kerrisk <mtk.manpages@gmail.com>2010-09-22 07:44:46 +0200
commit91e9dd28a57e20507f206e06bdb967620572c938 (patch)
tree00f16b4f3c91c7a6ce21eef7679961088a54e351 /man3
parentd931893ba31377009bc33c08d5313821a4000386 (diff)
downloadman-pages-91e9dd28a57e20507f206e06bdb967620572c938.tar.gz
rand.3: Clarify description of range of returned value
Reported-by: Mark Hills <mark@pogo.org.uk> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Diffstat (limited to 'man3')
-rw-r--r--man3/rand.310
1 files changed, 6 insertions, 4 deletions
diff --git a/man3/rand.3 b/man3/rand.3
index 4587c8bfda..88f651585f 100644
--- a/man3/rand.3
+++ b/man3/rand.3
@@ -60,7 +60,9 @@ _POSIX_C_SOURCE\ >=\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE
The
.BR rand ()
function returns a pseudo-random integer in
-the range [0,\ \fBRAND_MAX\fR].
+the range 0 to
+.BR RAND_MAX
+inclusive (i.e., the mathematical range [0,\ \fBRAND_MAX\fR]).
.PP
The
.BR srand ()
@@ -119,9 +121,9 @@ The
.BR rand ()
and
.BR rand_r ()
-functions return a value
-between 0 and
-.BR RAND_MAX .
+functions return a value between 0 and
+.BR RAND_MAX
+(inclusive).
The
.BR srand ()
function returns no value.