Skip to content

Conversation

@andypost
Copy link
Contributor

Ref https://bugs.php.net/bug.php?id=78008

  • free handle before return result
  • cleaned up remaining usage of MAXPACKET
  • update dns_get_mx() to use the same type

@andypost
Copy link
Contributor Author

AppVeyor failed test is unrelated

FAILED TEST SUMMARY
---------------------------------------------------------------------
Bug #79828: Segfault when trying to access non-existing variable [C:\projects\php-src\Zend\tests\bug79828.phpt]

- free handle before return result
- cleaned up remaining usage of MAXPACKET
- update dns_get_mx() to use the same approach
@nikic nikic changed the title dns_check_record() always return true on Alpinelinux #78088 dns_check_record() always return true on Alpinelinux #78008 Jul 15, 2020
@php-pulls php-pulls closed this in 2c57378 Jul 15, 2020
@andypost andypost deleted the 78008-dns branch July 15, 2020 14:31
@ekinhbayar
Copy link
Contributor

Hi o/ I've recently filed this bug report that is related to this PR. TL;DR is getmxrr seems to be still failing on our alpine based 7.4.9 pipelines. Notes from the quick discussion about this:
Nikita: Hm, looks like the function returns true for ancount==0

@andypost
Copy link
Contributor Author

@ekinhbayar Confirm that, when domain is wrong it still returns TRUE

$ php8 -r '$a=[];var_dump(dns_get_mx("gmail.com.aaaa", $a));var_dump($a);'
bool(true)
array(0) {
}

@andypost
Copy link
Contributor Author

that's because dns reports success but empty check is wrong

@ekinhbayar
Copy link
Contributor

Hi @andypost, for your information, Nikita recently commited a change for this, though I couldn't find the chance to test it yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants