mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-02-14 19:29:36 +01:00
Use Dns.GetHostEntryAsync.
I can't believe I missed this in the documentation.
This commit is contained in:
@@ -176,7 +176,7 @@ namespace Lidgren.Network
|
||||
|
||||
try
|
||||
{
|
||||
var entry = await Task.Factory.FromAsync(Dns.BeginGetHostEntry, Dns.EndGetHostEntry, ipOrHost, null);
|
||||
var entry = await Dns.GetHostEntryAsync(ipOrHost);
|
||||
return entry.AddressList;
|
||||
}
|
||||
catch (SocketException)
|
||||
|
||||
Reference in New Issue
Block a user