mirror of
https://github.com/phpbb/phpbb.git
synced 2025-05-06 07:35:29 +02:00
Removed uniqid() from make_bbcode_uid(). uniqid() was doing absolutely nothing for 20ms on each call ;(
git-svn-id: file:///svn/phpbb/trunk@1457 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
6f59a4054e
commit
ff0c26e892
@ -219,10 +219,13 @@ function bbencode_second_pass($text, $uid)
|
||||
|
||||
} // bbencode_second_pass()
|
||||
|
||||
// Need to initialize the random numbers only ONCE
|
||||
mt_srand( (double) microtime() * 1000000);
|
||||
|
||||
function make_bbcode_uid()
|
||||
{
|
||||
// Unique ID for this message..
|
||||
$uid = md5(uniqid(rand()));
|
||||
$uid = md5(mt_rand());
|
||||
$uid = substr($uid, 0, BBCODE_UID_LEN);
|
||||
|
||||
return $uid;
|
||||
@ -694,4 +697,4 @@ function bbcode_array_pop(&$stack)
|
||||
return($return_val);
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
|
Loading…
x
Reference in New Issue
Block a user