diff options
Diffstat (limited to 'nscd/cache.c')
-rw-r--r-- | nscd/cache.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/nscd/cache.c b/nscd/cache.c index fc293a36f3..d034bcb051 100644 --- a/nscd/cache.c +++ b/nscd/cache.c @@ -129,6 +129,10 @@ prune_cache (struct database *table, time_t now) size_t first = cnt + 1; size_t last = 0; + /* If this table is not actually used don't do anything. */ + if (cnt == 0) + return; + /* If we check for the modification of the underlying file we invalidate the entries also in this case. */ if (table->check_file) |