Imported Upstream version 5.10.1.2

Former-commit-id: 4a4d20b03e9e509d6d89eaf6a6226999e9214e2a
This commit is contained in:
Xamarin Public Jenkins (auto-signing)
2018-03-20 09:34:06 +00:00
parent 67cbe538ec
commit 206c528043
44 changed files with 57 additions and 61 deletions

View File

@ -320,11 +320,9 @@ namespace System.Net {
try {
IPAddress newAddress = IPAddress.Parse(h_addrlist[i]);
#pragma warning disable 618
if( (Socket.SupportsIPv6 && newAddress.AddressFamily == AddressFamily.InterNetworkV6) ||
(Socket.SupportsIPv4 && newAddress.AddressFamily == AddressFamily.InterNetwork) )
if( (Socket.OSSupportsIPv6 && newAddress.AddressFamily == AddressFamily.InterNetworkV6) ||
(Socket.OSSupportsIPv4 && newAddress.AddressFamily == AddressFamily.InterNetwork) )
addrlist.Add(newAddress);
#pragma warning restore 618
} catch (ArgumentNullException) {
/* Ignore this, as the
* internal call might have