From: kink Date: Thu, 21 Aug 2008 11:33:11 +0000 (+0000) Subject: use our existing random seeder function X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=b318c42e10d8f92bfbf8f083345251b7323619b0;p=squirrelmail.git use our existing random seeder function git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@13267 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/functions/global.php b/functions/global.php index d211773c..a5c24d02 100644 --- a/functions/global.php +++ b/functions/global.php @@ -544,13 +544,9 @@ function sqsetcookie($sName,$sValue='deleted',$iExpire=0,$sPath="",$sDomain="",$ * This code is borrowed from Gallery, session.php version 1.53.2.1 */ if (!function_exists('session_regenerate_id')) { - function make_seed() { - list($usec, $sec) = explode(' ', microtime()); - return (float)$sec + ((float)$usec * 100000); - } function php_combined_lcg() { - mt_srand(make_seed()); + sq_mt_randomize(); $tv = gettimeofday(); $lcg['s1'] = $tv['sec'] ^ (~$tv['usec']); $lcg['s2'] = mt_rand();