From a8c029f13070ef7c003527a04457810253ab75ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Mon, 16 Jun 2014 16:35:33 +0200 Subject: [PATCH] check if we really found a UPnP compatible NAT device --- OpenRA.Game/Network/UPnP.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OpenRA.Game/Network/UPnP.cs b/OpenRA.Game/Network/UPnP.cs index e05c4f26a5..97e61fe5d3 100644 --- a/OpenRA.Game/Network/UPnP.cs +++ b/OpenRA.Game/Network/UPnP.cs @@ -42,7 +42,7 @@ namespace OpenRA.Network Log.Write("server", "Stopping NAT discovery."); NatUtility.StopDiscovery(); - if (NatDevice == null) + if (NatDevice == null || NatDevice.GetType() != typeof(Mono.Nat.Upnp.UpnpNatDevice)) { Log.Write("server", "No NAT devices with UPnP enabled found within {0} ms deadline. Disabling automatic port forwarding.".F(Game.Settings.Server.NatDiscoveryTimeout)); Game.Settings.Server.NatDeviceAvailable = false;