Check if checkdnsrr() and getmxrr() functions exist before using them

pull/46/merge
Aleksander Machniak 12 years ago
parent f27c536401
commit 9ff3459d7b

@ -134,12 +134,12 @@ class rcube_utils
}
// find MX record(s)
if (getmxrr($domain_part, $mx_records)) {
if (!function_exists('getmxrr') || getmxrr($domain_part, $mx_records)) {
return true;
}
// find any DNS record
if (checkdnsrr($domain_part, 'ANY')) {
if (!function_exists('checkdnsrr') || checkdnsrr($domain_part, 'ANY')) {
return true;
}
}

Loading…
Cancel
Save