]> git.ipfire.org Git - thirdparty/git.git/commitdiff
base_ref_store_init(): remove submodule argument
authorMichael Haggerty <mhagger@alum.mit.edu>
Fri, 10 Feb 2017 11:16:17 +0000 (12:16 +0100)
committerJunio C Hamano <gitster@pobox.com>
Fri, 10 Feb 2017 19:13:26 +0000 (11:13 -0800)
This is another step towards weakening the 1:1 relationship between
ref_stores and submodules.

Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Reviewed-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs.c
refs/files-backend.c
refs/refs-internal.h

diff --git a/refs.c b/refs.c
index 07959ff3e65e1d0d67efe5e93a7f77362cd18f70..05af56b50a7d6ad953ba97b25e0b3a351148ea67 100644 (file)
--- a/refs.c
+++ b/refs.c
@@ -1477,8 +1477,7 @@ struct ref_store *get_ref_store(const char *submodule)
 }
 
 void base_ref_store_init(struct ref_store *refs,
-                        const struct ref_storage_be *be,
-                        const char *submodule)
+                        const struct ref_storage_be *be)
 {
        refs->be = be;
 }
index 5e135a49aa4ce468754bf3d5bd018cf03924ebc4..c9d2d284882d7c924452bcc9eea60062a35d483a 100644 (file)
@@ -980,7 +980,7 @@ static struct ref_store *files_ref_store_create(const char *submodule)
        struct files_ref_store *refs = xcalloc(1, sizeof(*refs));
        struct ref_store *ref_store = (struct ref_store *)refs;
 
-       base_ref_store_init(ref_store, &refs_be_files, submodule);
+       base_ref_store_init(ref_store, &refs_be_files);
 
        refs->submodule = submodule ? xstrdup(submodule) : "";
 
index 008822d67ccedd367fe010a261563adcca99227f..793c850e98fd0a2e2250b36a8efecf4293560245 100644 (file)
@@ -632,12 +632,11 @@ struct ref_store {
 };
 
 /*
- * Fill in the generic part of refs for the specified submodule and
- * add it to our collection of reference stores.
+ * Fill in the generic part of refs and add it to our collection of
+ * reference stores.
  */
 void base_ref_store_init(struct ref_store *refs,
-                        const struct ref_storage_be *be,
-                        const char *submodule);
+                        const struct ref_storage_be *be);
 
 /*
  * Return the ref_store instance for the specified submodule. For the