aboutsummaryrefslogtreecommitdiff
path: root/log-tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'log-tree.c')
-rw-r--r--log-tree.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/log-tree.c b/log-tree.c
index 8dba7be92..1a0e17079 100644
--- a/log-tree.c
+++ b/log-tree.c
@@ -149,10 +149,13 @@ static int add_graft_decoration(const struct commit_graft *graft, void *cb_data)
void load_ref_decorations(int flags)
{
if (!decoration_loaded) {
+ struct each_ref_fn_sha1_adapter wrapped_add_ref_decoration =
+ {add_ref_decoration, NULL};
+
decoration_loaded = 1;
decoration_flags = flags;
- for_each_ref(add_ref_decoration, NULL);
- head_ref(add_ref_decoration, NULL);
+ for_each_ref(each_ref_fn_adapter, &wrapped_add_ref_decoration);
+ head_ref(each_ref_fn_adapter, &wrapped_add_ref_decoration);
for_each_commit_graft(add_graft_decoration, NULL);
}
}