From 2d63c8d2d169f679e327032d951c2a0f6f1c18f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E5=9B=BD=E4=BC=9F?= <366193849@qq.com> Date: Wed, 28 Sep 2022 17:20:24 +0800 Subject: [PATCH] 2.1.5 --- Directory.Build.props | 2 +- FastGithub.PacketIntercept/Dns/DnsInterceptor.cs | 12 ------------ 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/Directory.Build.props b/Directory.Build.props index 64b3a6c..eb74ff8 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -1,6 +1,6 @@ - 2.1.4 + 2.1.5 enable net7.0 true diff --git a/FastGithub.PacketIntercept/Dns/DnsInterceptor.cs b/FastGithub.PacketIntercept/Dns/DnsInterceptor.cs index 0ced5d2..6b94103 100644 --- a/FastGithub.PacketIntercept/Dns/DnsInterceptor.cs +++ b/FastGithub.PacketIntercept/Dns/DnsInterceptor.cs @@ -35,18 +35,6 @@ namespace FastGithub.PacketIntercept.Dns [DllImport("dnsapi.dll", EntryPoint = "DnsFlushResolverCache", SetLastError = true)] private static extern void DnsFlushResolverCache(); - /// - /// 首次加载驱动往往有异常,所以要提前加载 - /// - static DnsInterceptor() - { - try - { - using (new WinDivert(Filter.False, WinDivertLayer.Network)) { } - } - catch (Exception) { } - } - /// /// dns拦截器 ///