sha1-name.c: move around the collect_ambiguous() function
[gitweb.git] / sha1-name.c
index cd3b133aaed5eae2d86a2b2d804ff5b1e0ca525e..9d7bbd3e96f3227026909ff92bbb443976683a1f 100644 (file)
@@ -372,6 +372,12 @@ static int show_ambiguous_object(const struct object_id *oid, void *data)
        return 0;
 }
 
+static int collect_ambiguous(const struct object_id *oid, void *data)
+{
+       oid_array_append(data, oid);
+       return 0;
+}
+
 static int get_short_oid(const char *name, int len, struct object_id *oid,
                          unsigned flags)
 {
@@ -421,12 +427,6 @@ static int get_short_oid(const char *name, int len, struct object_id *oid,
        return status;
 }
 
-static int collect_ambiguous(const struct object_id *oid, void *data)
-{
-       oid_array_append(data, oid);
-       return 0;
-}
-
 int for_each_abbrev(const char *prefix, each_abbrev_fn fn, void *cb_data)
 {
        struct oid_array collect = OID_ARRAY_INIT;