mirror of
https://github.com/php/php-src.git
synced 2024-09-22 02:17:32 +00:00
Fix #53092 - dns_get_record does not return false on dns server failure
This commit is contained in:
parent
a87300241f
commit
7b44790db5
@ -897,7 +897,13 @@ PHP_FUNCTION(dns_get_record)
|
||||
|
||||
if (n < 0) {
|
||||
php_dns_free_handle(handle);
|
||||
continue;
|
||||
if (h_errno == NO_DATA) {
|
||||
continue;
|
||||
} else {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Dns Query failed");
|
||||
zval_dtor(return_value);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
cp = answer.qb2 + HFIXEDSZ;
|
||||
|
Loading…
Reference in New Issue
Block a user