From 89f9dccb873dcb893c12a7a8c9bf67b4878fa8b9 Mon Sep 17 00:00:00 2001 From: ChsBuffer <33744752+chsbuffer@users.noreply.github.com> Date: Sat, 11 Sep 2021 01:19:01 +0800 Subject: [PATCH] Fix virtual adapter mode NAT type test result "Wrong STUN server" --- Netch/Controllers/MainController.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Netch/Controllers/MainController.cs b/Netch/Controllers/MainController.cs index b717cbf2..1bf80a06 100644 --- a/Netch/Controllers/MainController.cs +++ b/Netch/Controllers/MainController.cs @@ -34,6 +34,10 @@ namespace Netch.Controllers if (await DnsUtils.LookupAsync(server.Hostname) == null) throw new MessageException(i18N.Translate("Lookup Server hostname failed")); + + // TODO Disable NAT Type Test setting + // cache STUN Server ip to prevent "Wrong STUN Server" + DnsUtils.LookupAsync(Global.Settings.STUN_Server).Forget(); Server = server; Mode = mode;