[cmake-developers] OpenBSD and srand()/rand() changes

Ben Boeckel ben.boeckel at kitware.com
Sat Dec 13 13:05:00 EST 2014


On Thu, Dec 11, 2014 at 14:41:36 -0500, David Cole via cmake-developers wrote:
> Yes, setting an explicit seed should make subsequent calls to random
> be deterministic...

Well, *we* want that, but I don't think that OpenBSD is making an
*awful* decision here.

Even if you want deterministic, you're only deterministic on a single
platform, so if you want to get a deterministicly random (such an odd
phrase…) sequence, the best thing to do is to code up an Mersenne
Twister or something and ignore the rand/srand functions.

--Ben


More information about the cmake-developers mailing list