mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-08-18 09:00:42 +00:00
NetworkSession: Abort packet processing if handling triggered a disconnection
this shows up when requesting invalid data during resource pack handling, for example
This commit is contained in:
parent
11612ed0e2
commit
c417ecd30d
@ -415,6 +415,11 @@ class NetworkSession{
|
||||
$this->logger->debug($packet->getName() . ": " . base64_encode($buffer));
|
||||
throw PacketHandlingException::wrap($e, "Error processing " . $packet->getName());
|
||||
}
|
||||
if(!$this->isConnected()){
|
||||
//handling this packet may have caused a disconnection
|
||||
$this->logger->debug("Aborting batch processing due to server-side disconnection");
|
||||
break;
|
||||
}
|
||||
}
|
||||
}catch(PacketDecodeException|BinaryDataException $e){
|
||||
$this->logger->logException($e);
|
||||
|
Loading…
x
Reference in New Issue
Block a user