EXCUSE ME, HOW DARE YOU NOT LOG NETWORK ERRORS?!

This commit is contained in:
Dylan K. Taylor 2018-12-31 22:33:56 +00:00
parent 9ed1b5ca7f
commit 8752e363c9
2 changed files with 2 additions and 6 deletions

View File

@ -2491,9 +2491,7 @@ class Server{
$this->logger->debug("Unhandled raw packet from $address $port: " . bin2hex($payload));
}
}catch(\Throwable $e){
if(\pocketmine\DEBUG > 1){
$this->logger->logException($e);
}
$this->logger->logException($e);
$this->getNetwork()->blockAddress($address, 600);
}

View File

@ -94,9 +94,7 @@ class Network{
$interface->process();
}catch(\Throwable $e){
$logger = $this->server->getLogger();
if(\pocketmine\DEBUG > 1){
$logger->logException($e);
}
$logger->logException($e);
(new NetworkInterfaceCrashEvent($interface, $e))->call();