1
0
mirror of https://github.com/lidgren/lidgren-network-gen3.git synced 2026-05-15 22:56:30 +09:00

Fix to rebind same port as previously bound

This commit is contained in:
lidgren
2014-10-11 08:25:21 +00:00
parent 869ccb7bcb
commit 601666d9fb

View File

@@ -132,7 +132,7 @@ namespace Lidgren.Network
m_socket.SendBufferSize = m_configuration.SendBufferSize;
m_socket.Blocking = false;
var ep = (EndPoint)new IPEndPoint(m_configuration.LocalAddress, m_configuration.Port);
var ep = (EndPoint)new IPEndPoint(m_configuration.LocalAddress, reBind ? m_listenPort : m_configuration.Port);
m_socket.Bind(ep);
try