Commit Diff


commit - b9c41b542bba17bb3bcdd1ee0795845e086bcf4b
commit + 72acb3d8f4f1aa47fe21329180083cef02695490
blob - 928fcd8b030f65a1702ac22c29886c7438444548
blob + 9c2f8389ca9fc09f3499080dd949d464f4e85c67
--- gotadmin/gotadmin.c
+++ gotadmin/gotadmin.c
@@ -499,7 +499,7 @@ add_ref(struct got_reflist_entry **new, struct got_ref
 		err = got_ref_list(refs, repo, refname,
 		    got_ref_cmp_by_name, NULL);
 	} else {
-		err = got_reflist_insert(new, refs, ref, repo,
+		err = got_reflist_insert(new, refs, ref,
 		    got_ref_cmp_by_name, NULL);
 		if (err || *new == NULL /* duplicate */)
 			got_ref_close(ref);
blob - 89ec5aabb1b27cad61902560dc7e83551e00665b
blob + d242c363aa20248accbf7ebec5713fab795e4660
--- include/got_reference.h
+++ include/got_reference.h
@@ -131,8 +131,7 @@ void got_ref_list_free(struct got_reflist_head *);
  */
 const struct got_error *
 got_reflist_insert(struct got_reflist_entry **newp, struct got_reflist_head *refs,
-    struct got_reference *ref, struct got_repository *repo,
-    got_ref_cmp_cb cmp_cb, void *cmp_arg);
+    struct got_reference *ref, got_ref_cmp_cb cmp_cb, void *cmp_arg);
 
 /* Indicate whether the provided reference is symbolic (points at another
  * refernce) or not (points at an object ID). */
blob - 1f7e7d1033f43108af0c239bd50be641dccfc47d
blob + a326d18c6253b7ddd602904c535af4c487fcdfae
--- lib/reference.c
+++ lib/reference.c
@@ -810,8 +810,7 @@ done:
 
 const struct got_error *
 got_reflist_insert(struct got_reflist_entry **newp, struct got_reflist_head *refs,
-    struct got_reference *ref, struct got_repository *repo,
-    got_ref_cmp_cb cmp_cb, void *cmp_arg)
+    struct got_reference *ref, got_ref_cmp_cb cmp_cb, void *cmp_arg)
 {
 	const struct got_error *err;
 	struct got_reflist_entry *new, *re;
@@ -902,7 +901,7 @@ gather_on_disk_refs(struct got_reflist_head *refs, con
 				goto done;
 			if (ref) {
 				struct got_reflist_entry *new;
-				err = got_reflist_insert(&new, refs, ref, repo,
+				err = got_reflist_insert(&new, refs, ref,
 				    cmp_cb, cmp_arg);
 				if (err || new == NULL /* duplicate */)
 					got_ref_close(ref);
@@ -953,8 +952,7 @@ got_ref_list(struct got_reflist_head *refs, struct got
 		err = open_ref(&ref, path_refs, "", GOT_REF_HEAD, 0);
 		if (err)
 			goto done;
-		err = got_reflist_insert(&new, refs, ref, repo,
-		    cmp_cb, cmp_arg);
+		err = got_reflist_insert(&new, refs, ref, cmp_cb, cmp_arg);
 		if (err || new == NULL /* duplicate */)
 			got_ref_close(ref);
 		if (err && err->code != GOT_ERR_NOT_REF)
@@ -973,7 +971,7 @@ got_ref_list(struct got_reflist_head *refs, struct got
 				goto done;
 			/* Try to look up references in a given namespace. */
 		} else {
-			err = got_reflist_insert(&new, refs, ref, repo,
+			err = got_reflist_insert(&new, refs, ref,
 			    cmp_cb, cmp_arg);
 			if (err || new == NULL /* duplicate */)
 				got_ref_close(ref);
@@ -1065,7 +1063,7 @@ got_ref_list(struct got_reflist_head *refs, struct got
 						continue;
 					}
 				}
-				err = got_reflist_insert(&new, refs, ref, repo,
+				err = got_reflist_insert(&new, refs, ref,
 				    cmp_cb, cmp_arg);
 				if (err || new == NULL /* duplicate */)
 					got_ref_close(ref);
@@ -1316,7 +1314,7 @@ delete_packed_ref(struct got_reference *delref, struct
 			continue;
 		}
 
-		err = got_reflist_insert(&new, &refs, ref, repo,
+		err = got_reflist_insert(&new, &refs, ref,
 		    got_ref_cmp_by_name, NULL);
 		if (err || new == NULL /* duplicate */)
 			got_ref_close(ref);