dns
dns copied to clipboard
cache: remove all expired elements from oldest to newest
instead of the single oldest element
EDIT: right now the expiry time depends on the current time + lowest ttl of dns answers, so it would need a sorted insertion, which could hurt performance. This doesn't seem like a priority, will check again later.