Merge branch 'jc/maint-1.6.0-read-tree-overlay'
[gitweb.git] / refs.c
diff --git a/refs.c b/refs.c
index 6eb5f5384611bb5d159d892a1bfd120d72e54b9b..b2a37e1185704733faa4d8395b996dc80d3f19ef 100644 (file)
--- a/refs.c
+++ b/refs.c
@@ -1628,10 +1628,10 @@ int update_ref(const char *action, const char *refname,
        return 0;
 }
 
-struct ref *find_ref_by_name(struct ref *list, const char *name)
+struct ref *find_ref_by_name(const struct ref *list, const char *name)
 {
        for ( ; list; list = list->next)
                if (!strcmp(list->name, name))
-                       return list;
+                       return (struct ref *)list;
        return NULL;
 }