Subject: Re: Thread safety

Re: Thread safety

From: Eino Tuominen <>
Date: Fri, 28 Mar 2008 14:52:05 +0200

Daniel Stenberg wrote:
> The Linux man page suggests using rand_r() or even better drand48_r()
> instead. What's the best alternative on Solaris 9?

At least rand_r() and drand48() are "MT-Level = Safe" on Solaris 9. I
think rand_r() would be the most portable, though it's far from
cryptographically safe. But if rand() was safe enough for the use, then
rand_r() should be okay, too.

   Eino Tuominen
Received on 2008-03-28