]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
(__setstate_r): Allow RNGs of type 4.
authorUlrich Drepper <drepper@redhat.com>
Sun, 26 Mar 2000 18:15:40 +0000 (18:15 +0000)
committerUlrich Drepper <drepper@redhat.com>
Sun, 26 Mar 2000 18:15:40 +0000 (18:15 +0000)
stdlib/random_r.c

index 445bc95d3591321253b06b63c457478cc1e56ed2..19edf2a2d00fd8815d829da02a318d849af2d6e2 100644 (file)
@@ -285,7 +285,7 @@ __setstate_r (arg_state, buf)
     old_state[-1] = (MAX_TYPES * (buf->rptr - old_state)) + old_type;
 
   type = new_state[0] % MAX_TYPES;
-  if (type < TYPE_0 || type >= TYPE_4)
+  if (type < TYPE_0 || type > TYPE_4)
     goto fail;
 
   buf->rand_deg = degree = random_poly_info.degrees[type];