Skip to content

Commit 254110c

Browse files
committed
Merge branch '4.4' into 5.0
* 4.4: [VarDumper] fix side-effect by not using mt_rand()
2 parents e6a5be9 + 6dae469 commit 254110c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Cloner/VarCloner.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ protected function doClone($var)
4545
// or null if the original value is used directly
4646

4747
if (!$gid = self::$gid) {
48-
$gid = self::$gid = uniqid(mt_rand(), true); // Unique string used to detect the special $GLOBALS variable
48+
$gid = self::$gid = md5(random_bytes(6)); // Unique string used to detect the special $GLOBALS variable
4949
}
5050
$arrayStub = new Stub();
5151
$arrayStub->type = Stub::TYPE_ARRAY;

0 commit comments

Comments
 (0)