The MacProxy class uses CFNetwork, but since CFNetwork is not a public
framework on watchOS, we can't use it.
So remove MacProxy completely (it only contains internal classes), and throw
PlatformNotSupportedException in any API that used it (the managed networking
stack is not supported on watchOS anyway, so this should be safe).
https://bugzilla.xamarin.com/show_bug.cgi?id=45847
using System.Collections;
using System.Collections.Generic;
using System.Text.RegularExpressions;
+#if !MONOTOUCH_WATCH
using Mono.Net;
+#endif
namespace System.Net
{
Mono.Net.Security/MonoTlsStream.cs
Mono.Net.Security/NoReflectionHelper.cs
Mono.Net.Security/SystemCertificateValidator.cs
+System.Net/MacProxy.cs
System.Net.Mail/SmtpClient.cs
System.Net.Security/SslStream.cs
System.Net.Sockets/TcpClient.cs
#if MONO
public static IWebProxy CreateDefaultProxy ()
{
-#if MONOTOUCH
+#if MONOTOUCH_WATCH
+ throw new PlatformNotSupportedException ();
+#elif MONOTOUCH
return Mono.Net.CFNetwork.GetDefaultProxy ();
#elif MONODROID
// Return the system web proxy. This only works for ICS+.