From b541351a0a52d156085b0f1e06079c1c2e409eb8 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Wed, 2 Nov 2016 23:37:57 -0700 Subject: ignore flags to dns_get_record() and look for anything --- include/network.php | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'include/network.php') diff --git a/include/network.php b/include/network.php index 7cfd3a5e6..fe360c425 100644 --- a/include/network.php +++ b/include/network.php @@ -495,10 +495,13 @@ function z_dns_check($h,$check_mx = 0) { && \App::$config['system']['do_not_check_dns']) return true; - $opts = DNS_A + DNS_CNAME + DNS_PTR; - if($check_mx) - $opts += DNS_MX; - return((@dns_get_record($h, $opts) || filter_var($h, FILTER_VALIDATE_IP)) ? true : false); + + //$opts = DNS_A + DNS_CNAME + DNS_PTR; + //if($check_mx) + // $opts += DNS_MX; + // Specific record type flags are unreliable on FreeBSD and Mac, + // so now we'll ignore these and just check for the existence of any DNS record. + return((@dns_get_record($h) || filter_var($h, FILTER_VALIDATE_IP)) ? true : false); } -- cgit v1.2.3