This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libc/24092] on seeds 0 and 1, srandom() initializes the random number generator in the same way


https://sourceware.org/bugzilla/show_bug.cgi?id=24092

--- Comment #25 from Vincent Lefèvre <vincent-srcware at vinc17 dot net> ---
(In reply to Andreas Schwab from comment #24)
> The random state is also global.

But the random() function is documented to be thread-safe.

I've eventually switched to the non-portable random_r() for reproducibility,
but reproducibility was just a minor additional feature in my application.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]