Fixed uncaught exception when retrieving a packet from the pool

This commit is contained in:
Dylan K. Taylor 2023-03-22 22:24:25 +00:00
parent 52ea4feac0
commit b11457d605
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D

View File

@ -120,6 +120,7 @@ use pocketmine\player\XboxLivePlayerInfo;
use pocketmine\Server;
use pocketmine\timings\Timings;
use pocketmine\utils\AssumptionFailedError;
use pocketmine\utils\BinaryDataException;
use pocketmine\utils\BinaryStream;
use pocketmine\utils\ObjectSet;
use pocketmine\utils\TextFormat;
@ -414,7 +415,7 @@ class NetworkSession{
throw PacketHandlingException::wrap($e, "Error processing " . $packet->getName());
}
}
}catch(PacketDecodeException $e){
}catch(PacketDecodeException|BinaryDataException $e){
$this->logger->logException($e);
throw PacketHandlingException::wrap($e, "Packet batch decode error");
}