mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 17:59:48 +00:00
AsyncPool: Slightly reduce worker memory usage with more conservative start options
this results in a memory footprint reduction of maybe 4MB for a total of 8 workers. Not much, but it's something.
This commit is contained in:
@ -634,4 +634,21 @@ class Utils{
|
||||
|
||||
return array_combine($matches[1], array_map("trim", $matches[2]));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $severity
|
||||
* @param string $message
|
||||
* @param string $file
|
||||
* @param int $line
|
||||
*
|
||||
* @return bool
|
||||
* @throws \ErrorException
|
||||
*/
|
||||
public static function errorExceptionHandler(int $severity, string $message, string $file, int $line) : bool{
|
||||
if(error_reporting() & $severity){
|
||||
throw new \ErrorException($message, 0, $severity, $file, $line);
|
||||
}
|
||||
|
||||
return true; //stfu operator
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user