* sofia-resolv/sres_cache.h: added prototype for sres_cache_clean()
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@11761
d0543943-73ff-0310-b7d9-
9358b9ac24b2
/** Free and zero one record. */
SRESPUBFUN void sres_cache_free_one(sres_cache_t *, sres_record_t *answer);
+/** Remove old records from cache. */
+SRESPUBFUN void sres_cache_clean(sres_cache_t *cache, time_t now);
+
/** Allocate a cache record */
SRESPUBFUN
sres_record_t *sres_cache_alloc_record(sres_cache_t *cache,
return result;
}
-/** Remove entries from cache. */
+/** Remove old records from cache.
+ *
+ * Remove entries older than @a now from the cache.
+ *
+ * @param cache pointer to DNS cache object
+ * @param now remove older than this time
+ */
void sres_cache_clean(sres_cache_t *cache, time_t now)
{
size_t i;