You've already forked lidgren-network-gen3
mirror of
https://github.com/lidgren/lidgren-network-gen3.git
synced 2026-05-17 23:56:30 +09:00
Fix possible NullArgumentException throw by using a null return.
This commit is contained in:
@@ -72,7 +72,7 @@ namespace Lidgren.Network
|
|||||||
public static NetEndPoint Resolve(string ipOrHost, int port)
|
public static NetEndPoint Resolve(string ipOrHost, int port)
|
||||||
{
|
{
|
||||||
var adr = Resolve(ipOrHost);
|
var adr = Resolve(ipOrHost);
|
||||||
return new NetEndPoint(adr, port);
|
return adr == null ? null : new NetEndPoint(adr, port);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static IPAddress s_broadcastAddress;
|
private static IPAddress s_broadcastAddress;
|
||||||
|
|||||||
Reference in New Issue
Block a user