From 0e1d656e85e1bbc80e9e8adcfb2c07a8bc0d4bb8 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 12 Feb 2018 03:13:01 +0300 Subject: Fix code style. Add missing actorManager null checks. --- src/net/eathena/homunculusrecv.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/net/eathena/homunculusrecv.cpp') diff --git a/src/net/eathena/homunculusrecv.cpp b/src/net/eathena/homunculusrecv.cpp index 476564d22..0f0d619ae 100644 --- a/src/net/eathena/homunculusrecv.cpp +++ b/src/net/eathena/homunculusrecv.cpp @@ -77,6 +77,8 @@ void HomunculusRecv::processHomunculusSkills(Net::MessageIn &msg) void HomunculusRecv::processHomunculusData(Net::MessageIn &msg) { + if (actorManager == nullptr) + return; msg.readUInt8("unused"); const int cmd = msg.readUInt8("state"); const BeingId id = msg.readBeingId("homunculus id"); @@ -111,6 +113,8 @@ void HomunculusRecv::processHomunculusData(Net::MessageIn &msg) void HomunculusRecv::processHomunculusInfo(Net::MessageIn &msg) { + if (actorManager == nullptr) + return; const std::string name = msg.readString(24, "name"); msg.readUInt8("flags"); // 0x01 - renamed, 0x02 - vaporize, 0x04 - alive const int level = msg.readInt16("level"); -- cgit v1.2.3-70-g09d2