summaryrefslogtreecommitdiff
path: root/src/odb.c
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2019-02-20 10:40:06 +0100
committerPatrick Steinhardt <ps@pks.im>2019-02-21 13:35:56 +0100
commitbbdcd45055ca702eb5083ebf0c70f04c15642f78 (patch)
tree98a4fe91213837ebf834d02772fe588612f9e84a /src/odb.c
parent9eb098d8614bdd0365140f6614441465123ce903 (diff)
downloadlibgit2-bbdcd45055ca702eb5083ebf0c70f04c15642f78.tar.gz
cache: fix misnaming of `git_cache_free`
Functions that free a structure's contents but not the structure itself shall be named `dispose` in the libgit2 project, but the function `git_cache_free` does not follow this naming pattern. Fix this by renaming it to `git_cache_dispose` and adjusting all callers to make use of the new name.
Diffstat (limited to 'src/odb.c')
-rw-r--r--src/odb.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/odb.c b/src/odb.c
index 6a7e7ca7e..f85a3417b 100644
--- a/src/odb.c
+++ b/src/odb.c
@@ -448,7 +448,7 @@ int git_odb_new(git_odb **out)
return -1;
}
if (git_vector_init(&db->backends, 4, backend_sort_cmp) < 0) {
- git_cache_free(&db->own_cache);
+ git_cache_dispose(&db->own_cache);
git__free(db);
return -1;
}
@@ -686,7 +686,7 @@ static void odb_free(git_odb *db)
}
git_vector_free(&db->backends);
- git_cache_free(&db->own_cache);
+ git_cache_dispose(&db->own_cache);
git__memzero(db, sizeof(*db));
git__free(db);