]> git.ipfire.org Git - thirdparty/bind9.git/commit
clean up unnecessary code in qpcache
authorEvan Hunt <each@isc.org>
Thu, 23 Jan 2025 07:08:04 +0000 (23:08 -0800)
committerEvan Hunt <each@isc.org>
Tue, 18 Feb 2025 20:15:00 +0000 (20:15 +0000)
commit5281c708d3f64f11e40e35399a22380d0190328f
treea8c5c7d2d950809b1b22442baf40a00d5e8c7b3e
parentd34414c47b9af5334c53aedb7eebee4515057f7a
clean up unnecessary code in qpcache

some code was left in the cache database implementation after
it was separated from the zone database, and can be cleaned up
and refactored now:

- the DNS_SLABHEADERATTR_IGNORE flag is never set in the cache
- support for loading the cache from was removed, but the add()
  function still had a 'loading' flag that's always false
- two different macros were used for checking the
  DNS_SLABHEADERATTR_NONEXISTENT flag - EXISTS() and NONEXISTENT().
  it's clearer to just use EXISTS().
- the cache doesn't support versions, so it isn't necessary to
  walk down the 'down' pointer chain when iterating through the
  cache or looking for a header to update.  'down' now only points
  to records that are deleted from the cache but have not yet been
  purged from memory. this allows us to simplify both the iterator
  and the add() function.
lib/dns/qpcache.c