Merge pull request #4646 from elecyb/crash1
Core/PacketIO: Fix crash and exploit caused when client sends tampered m...
This commit is contained in:
@@ -472,18 +472,7 @@ void WorldSession::HandleSetActiveMoverOpcode(WorldPacket &recv_data)
|
||||
|
||||
if (GetPlayer()->IsInWorld())
|
||||
{
|
||||
if (Unit* mover = ObjectAccessor::GetUnit(*GetPlayer(), guid))
|
||||
{
|
||||
GetPlayer()->SetMover(mover);
|
||||
if (mover != GetPlayer() && mover->canFly())
|
||||
{
|
||||
WorldPacket data(SMSG_MOVE_SET_CAN_FLY, 12);
|
||||
data.append(mover->GetPackGUID());
|
||||
data << uint32(0);
|
||||
SendPacket(&data);
|
||||
}
|
||||
}
|
||||
else
|
||||
if (_player->m_mover->GetGUID() != guid)
|
||||
{
|
||||
sLog->outError("HandleSetActiveMoverOpcode: incorrect mover guid: mover is " UI64FMTD " (%s - Entry: %u) and should be " UI64FMTD, guid, GetLogNameForGuid(guid), GUID_ENPART(guid), _player->m_mover->GetGUID());
|
||||
GetPlayer()->SetMover(GetPlayer());
|
||||
|
||||
Reference in New Issue
Block a user