Explorar o código

fix fakedns is nil

Shelikhoo %!s(int64=4) %!d(string=hai) anos
pai
achega
1df432218e
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      app/dispatcher/fakednssniffer.go

+ 1 - 1
app/dispatcher/fakednssniffer.go

@@ -18,7 +18,7 @@ import (
 func newFakeDNSSniffer(ctx context.Context) (protocolSnifferWithMetadata, error) {
 	var fakeDNSEngine dns.FakeDNSEngine
 	{
-		fakeDNSEngineFeat := core.MustFromContext(ctx).GetFeature(fakeDNSEngine)
+		fakeDNSEngineFeat := core.MustFromContext(ctx).GetFeature((*dns.FakeDNSEngine)(nil))
 		if fakeDNSEngineFeat != nil {
 			fakeDNSEngine = fakeDNSEngineFeat.(dns.FakeDNSEngine)
 		}