aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/stdlib/rand48.c
diff options
context:
space:
mode:
authorMatthew Green <mrg@redhat.com>2002-02-03 09:24:18 +0000
committerMatthew Green <mrg@redhat.com>2002-02-03 09:24:18 +0000
commit8195aff714f2ea5d680a5129a1d54af388e90355 (patch)
tree683ff47f4802385e669491dda42bf8050772dbdf /newlib/libc/stdlib/rand48.c
parentad67ada2fc7cdb361643d506701e274a67d796f9 (diff)
downloadnewlib-8195aff714f2ea5d680a5129a1d54af388e90355.zip
newlib-8195aff714f2ea5d680a5129a1d54af388e90355.tar.gz
newlib-8195aff714f2ea5d680a5129a1d54af388e90355.tar.bz2
* implement a new `struct _reent' that is significantly smaller. use this
if _REENT_SMALL is defined in config.h. define this for xstormy16.
Diffstat (limited to 'newlib/libc/stdlib/rand48.c')
-rw-r--r--newlib/libc/stdlib/rand48.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/newlib/libc/stdlib/rand48.c b/newlib/libc/stdlib/rand48.c
index c65af12..17fd04e 100644
--- a/newlib/libc/stdlib/rand48.c
+++ b/newlib/libc/stdlib/rand48.c
@@ -163,6 +163,7 @@ _DEFUN (__dorand48, (r, xseed),
unsigned long accu;
unsigned short temp[2];
+ _REENT_CHECK_RAND48(r);
accu = (unsigned long) __rand48_mult[0] * (unsigned long) xseed[0] +
(unsigned long) __rand48_add;
temp[0] = (unsigned short) accu; /* lower 16 bits */