From ea8e518cdce77a310763a69aedf67f2c9853d7ca Mon Sep 17 00:00:00 2001 From: joseph Date: Thu, 22 Oct 2009 19:51:30 +0000 Subject: Merge changes between r9028 and r9122 from /fsf/trunk. git-svn-id: svn://svn.eglibc.org/trunk@9123 7b3dc134-2b1b-0410-93df-9e9f96275f8d --- libc/stdlib/rand_r.c | 4 ++-- libc/stdlib/random_r.c | 6 ++---- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'libc/stdlib') diff --git a/libc/stdlib/rand_r.c b/libc/stdlib/rand_r.c index 3d49c92de..6a35112f2 100644 --- a/libc/stdlib/rand_r.c +++ b/libc/stdlib/rand_r.c @@ -1,5 +1,5 @@ -/* Reentrant random function frm POSIX.1c. - Copyright (C) 1996, 1999 Free Software Foundation, Inc. +/* Reentrant random function from POSIX.1c. + Copyright (C) 1996, 1999, 2009 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1996. diff --git a/libc/stdlib/random_r.c b/libc/stdlib/random_r.c index a30055f59..90a157f9c 100644 --- a/libc/stdlib/random_r.c +++ b/libc/stdlib/random_r.c @@ -255,10 +255,8 @@ __initstate_r (seed, arg_state, n, buf) else if (n < BREAK_1) { if (n < BREAK_0) - { - __set_errno (EINVAL); - goto fail; - } + goto fail; + type = TYPE_0; } else -- cgit v1.2.3