Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Spahr-Summers <Justin.SpahrSummers@gmail.com>2012-12-09 14:40:16 +0400
committerJustin Spahr-Summers <Justin.SpahrSummers@gmail.com>2012-12-09 14:40:16 +0400
commit1d009603343786f6022ef690e513f183c5840747 (patch)
tree890092048875a4202b57e6d43dc6ea0ee3d86e2f /src/cache.c
parent2bb1c7aa2629e1e4e3a5f04d494b16957da849e1 (diff)
orite C89
Diffstat (limited to 'src/cache.c')
-rw-r--r--src/cache.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cache.c b/src/cache.c
index 67801758d..cbd360a02 100644
--- a/src/cache.c
+++ b/src/cache.c
@@ -83,12 +83,12 @@ void *git_cache_try_store(git_cache *cache, void *_entry)
}
{
+ git_cached_obj *node = cache->nodes[hash & cache->size_mask];
+
/* increase the refcount on this object, because
* the cache now owns it */
git_cached_obj_incref(entry);
- git_cached_obj *node = cache->nodes[hash & cache->size_mask];
-
if (node == NULL) {
cache->nodes[hash & cache->size_mask] = entry;
} else if (git_oid_cmp(&node->oid, &entry->oid) == 0) {