You've already forked lidgren-network-gen3
mirror of
https://github.com/lidgren/lidgren-network-gen3.git
synced 2026-05-06 02:11:06 +09:00
BREAKING CHANGE: NatIntroductionSuccess is now DISABLED by default; you must enable it using EnableMessageType
Added GarbageThrowerSample - a small library sample that sends random and semi-random data to detect problems Made lots of changes that caused exceptions when malformed data was received
This commit is contained in:
@@ -499,6 +499,7 @@ namespace Lidgren.Network
|
||||
msg.m_senderConnection = sender;
|
||||
msg.m_senderEndPoint = ipsender;
|
||||
msg.m_bitLength = payloadBitLength;
|
||||
|
||||
Buffer.BlockCopy(m_receiveBuffer, ptr, msg.m_data, 0, payloadByteLength);
|
||||
if (sender != null)
|
||||
{
|
||||
@@ -594,10 +595,12 @@ namespace Lidgren.Network
|
||||
HandleIncomingDiscoveryResponse(now, senderEndPoint, ptr, payloadByteLength);
|
||||
return;
|
||||
case NetMessageType.NatIntroduction:
|
||||
HandleNatIntroduction(ptr);
|
||||
if (m_configuration.IsMessageTypeEnabled(NetIncomingMessageType.NatIntroductionSuccess))
|
||||
HandleNatIntroduction(ptr);
|
||||
return;
|
||||
case NetMessageType.NatPunchMessage:
|
||||
HandleNatPunch(ptr, senderEndPoint);
|
||||
if (m_configuration.IsMessageTypeEnabled(NetIncomingMessageType.NatIntroductionSuccess))
|
||||
HandleNatPunch(ptr, senderEndPoint);
|
||||
return;
|
||||
case NetMessageType.ConnectResponse:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user