fix(Core/Packet): fix crash happening when someone sends small packets that is processed directly to WorldSocket (#2669)
This commit is contained in:
@@ -676,7 +676,15 @@ int WorldSocket::ProcessIncoming(WorldPacket* new_pct)
|
|||||||
switch (opcode)
|
switch (opcode)
|
||||||
{
|
{
|
||||||
case CMSG_PING:
|
case CMSG_PING:
|
||||||
return HandlePing (*new_pct);
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
return HandlePing(*new_pct);
|
||||||
|
}
|
||||||
|
catch (ByteBufferPositionException const&) {}
|
||||||
|
sLog->outError("WorldSocket::ReadDataHandler(): client sent malformed CMSG_PING");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
case CMSG_AUTH_SESSION:
|
case CMSG_AUTH_SESSION:
|
||||||
if (m_Session)
|
if (m_Session)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user