mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-09 11:31:49 +00:00
Fixed worker memory dump crash
$GLOBALS does not exist at all on threads :(
This commit is contained in:
parent
2a8be527d7
commit
6ddbdc9dc1
@ -330,7 +330,7 @@ class MemoryManager{
|
|||||||
file_put_contents($outputFolder . "/staticProperties.js", json_encode($staticProperties, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
file_put_contents($outputFolder . "/staticProperties.js", json_encode($staticProperties, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
||||||
MainLogger::getLogger()->info("[Dump] Wrote $staticCount static properties");
|
MainLogger::getLogger()->info("[Dump] Wrote $staticCount static properties");
|
||||||
|
|
||||||
if($GLOBALS !== null){ //This might be null if we're on a different thread
|
if(isset($GLOBALS)){ //This might be null if we're on a different thread
|
||||||
$globalVariables = [];
|
$globalVariables = [];
|
||||||
$globalCount = 0;
|
$globalCount = 0;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user