diff --git a/MSDKDns/Resolver/HttpsDnsResolver.m b/MSDKDns/Resolver/HttpsDnsResolver.m index be55da8..2ab0439 100644 --- a/MSDKDns/Resolver/HttpsDnsResolver.m +++ b/MSDKDns/Resolver/HttpsDnsResolver.m @@ -43,7 +43,7 @@ - (void)startWithDomains:(NSArray *)domains TimeOut:(float)timeOut DnsId:(int)dn id delegate = self.delegate; self.errorCode = MSDKDns_UnResolve; if (!domainStr || domainStr.length == 0) { - MSDKDNSLOG(@"HttpDns Domain is must needed!"); + MSDKDNSLOG(@"HttpDns Domain is must needed!"); self.domainInfo = nil; self.isFinished = YES; self.isSucceed = NO; @@ -266,6 +266,10 @@ - (NSDictionary *)parseAllIPString:(NSString *)iPstring { } } + // 当双栈解析请求中ipv4和ipv6的结果都不符合预期,就返回ni走getDomainError逻辑 + if (bothIPDict.count == 0){ + return nil; + } return bothIPDict; } else { BOOL use4A = false;