]> git.ipfire.org Git - thirdparty/bind9.git/commit
fix: test: Fix an issue with unreachable cache's unit test
authorArаm Sаrgsyаn <aram@isc.org>
Wed, 3 Dec 2025 10:16:08 +0000 (10:16 +0000)
committerArаm Sаrgsyаn <aram@isc.org>
Wed, 3 Dec 2025 10:16:08 +0000 (10:16 +0000)
commit93fa62c3e0b95d7a9d68d974ed5dd54b84fbd49a
tree75e77487ed5b0e0856b8197ee6582552552b91e1
parentb37833615531b0eedabffa1a14771edc305d8d86
parent8c8bf4e45dc6e742dd27363e9613411dc1edd761
fix: test: Fix an issue with unreachable cache's unit test

The isc_stdtime_now() function used by dns_unreachcache_find() to
check if the entry needs to be expired has a one-second resolution,
and the test sleeps for 1 second and then for the amount of the
expiration interval, which in a worst-case scenario can cause the
test to fail, because the entry was expected to be expired but it
wasn't. Sleep for 2 seconds instead of 1 to avoid the timing
resolution issue.

Closes #5601

Merge branch '5601-unreachable-cache-expire-test-fix' into 'main'

See merge request isc-projects/bind9!11224