rand() without srand() doesn't work with certain php.ini
| Bug #26381 | rand() without srand() doesn't work with certain php.ini | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Submitted: | 2003-11-24 08:21 UTC | Modified: | 2004-01-26 20:00 UTC |
|
||||||||||
| From: | spam at vrana dot cz | Assigned: | ||||||||||||
| Status: | Closed | Package: | Scripting Engine problem | |||||||||||
| PHP Version: | 4CVS-2003-12-7 | OS: | win32 only | |||||||||||
| Private report: | No | CVE-ID: | None | |||||||||||
[2003-11-24 08:21 UTC] spam at vrana dot cz
Description: ------------ Function rand() without setting random seed by srand() returns always the same value. It doesn't work only on Windows PHP-CLI. As Windows Apache module and also on Linux PHP-CLI it works as it should. Reproduce code: --------------- echo rand(); Expected result: ---------------- (random value) Actual result: -------------- 24849
Patches
Pull Requests
History
AllCommentsChangesGit/SVN commits
[2003-12-02 10:57 UTC] spam at vrana dot cz
[2003-12-02 17:11 UTC] sniper@php.net
[2003-12-03 03:31 UTC] spam at vrana dot cz
[2003-12-07 13:54 UTC] sniper@php.net
[2004-01-19 14:04 UTC] sniper@php.net
[2004-01-20 03:47 UTC] spam at vrana dot cz