fix(Core/WorldSession): prevent crash in SendPacket (#6045)
This commit is contained in:
parent
9bea4dc011
commit
3716ddf3e4
1 changed files with 5 additions and 1 deletions
|
|
@ -200,7 +200,11 @@ ObjectGuid::LowType WorldSession::GetGuidLow() const
|
|||
/// Send a packet to the client
|
||||
void WorldSession::SendPacket(WorldPacket const* packet)
|
||||
{
|
||||
ASSERT(packet->GetOpcode() != NULL_OPCODE);
|
||||
if (packet->GetOpcode() == NULL_OPCODE)
|
||||
{
|
||||
LOG_ERROR("server", "WorldSession::SendPacket(packet) called, but packet->GetOpcode() was NULL_OPCODE");
|
||||
return;
|
||||
}
|
||||
|
||||
if (!m_Socket)
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue