Bug #18419 Updated: No way to get current rand seed

From: Date: Thu, 18 Jul 2002 19:20:46 +0000
Subject: Bug #18419 Updated: No way to get current rand seed
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-14555@lists.php.net to get a copy of this message
ID: 18419 Updated by: rasmus@php.net Reported By: peter_ammon@rocketmail.com -Status: Open +Status: Feedback Bug Type: Feature/Change Request Operating System: RedHat Linux PHP Version: 4.2.1 New Comment: I don't really see the scenario where setting a known seed with srand() wouldn't be sufficient. Previous Comments: ------------------------------------------------------------------------ [2002-07-18 15:17:41] peter_ammon@rocketmail.com It would be nice if there were a way to retrieve the current random number seed (or state if it maintains more information than just the seed), so the random number generator could be reseeded with it. Some code depends upon the fact that rand will produce the same sequence starting with a given seed, and without a way to retrieve the seed, it's impossible to put functions that call rand() a variable number of times in such code. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=18419&edit=1

« previous php.bugs (#14555) next »