Network: Don't ignore retval of raw handlers

This commit is contained in:
Dylan K. Taylor 2019-03-24 18:31:32 +00:00
parent d0940e4be2
commit 97ccc6e880

View File

@ -237,9 +237,8 @@ class Network{
$handled = false; $handled = false;
foreach($this->rawPacketHandlers as $handler){ foreach($this->rawPacketHandlers as $handler){
if(preg_match($handler->getPattern(), $packet) === 1){ if(preg_match($handler->getPattern(), $packet) === 1){
$handled = true;
try{ try{
$handler->handle($interface, $address, $port, $packet); $handled = $handler->handle($interface, $address, $port, $packet);
}catch(BadPacketException $e){ }catch(BadPacketException $e){
$this->logger->error("Bad raw packet from /$address:$port: " . $e->getMessage()); $this->logger->error("Bad raw packet from /$address:$port: " . $e->getMessage());
$this->blockAddress($address, 600); $this->blockAddress($address, 600);