chiark / gitweb /
journal: delete unused function mmap_cache_close_context
authorMichal Schmidt <mschmidt@redhat.com>
Wed, 3 Dec 2014 17:23:23 +0000 (18:23 +0100)
committerMichal Schmidt <mschmidt@redhat.com>
Fri, 12 Dec 2014 23:47:23 +0000 (00:47 +0100)
This never had any callers. Contexts are freed when the MMapCache is
freed.

src/journal/mmap-cache.c
src/journal/mmap-cache.h

index f34d260856127e6493ff08db3ba5052515f25f47..949f97819bcd90acefd9a8c219e9790bfa507e8a 100644 (file)
@@ -591,18 +591,6 @@ void mmap_cache_close_fd(MMapCache *m, int fd) {
         fd_free(f);
 }
 
-void mmap_cache_close_context(MMapCache *m, unsigned context) {
-        Context *c;
-
-        assert(m);
-
-        c = hashmap_get(m->contexts, UINT_TO_PTR(context + 1));
-        if (!c)
-                return;
-
-        context_free(c);
-}
-
 unsigned mmap_cache_get_hit(MMapCache *m) {
         assert(m);
 
index 3e2ffbbfd15f1cb91f58f014f02d6367468af090..543a2bf2d05757965af7b4a1fb4813f68ede067e 100644 (file)
@@ -42,7 +42,6 @@ int mmap_cache_get(
         struct stat *st,
         void **ret);
 void mmap_cache_close_fd(MMapCache *m, int fd);
-void mmap_cache_close_context(MMapCache *m, unsigned context);
 
 unsigned mmap_cache_get_hit(MMapCache *m);
 unsigned mmap_cache_get_missed(MMapCache *m);