]> git.ipfire.org Git - thirdparty/git.git/blobdiff - transport.c
Merge branch 'ta/string-list-init'
[thirdparty/git.git] / transport.c
index 3e425709fded6e384add10aeff7f19455259ff46..80ed1262c29e8e3ec1443e06383c4ee9b7d14173 100644 (file)
@@ -1176,10 +1176,8 @@ int transport_push(struct transport *transport,
                if ((flags & (TRANSPORT_RECURSE_SUBMODULES_ON_DEMAND |
                              TRANSPORT_RECURSE_SUBMODULES_CHECK)) && !is_bare_repository()) {
                        struct ref *ref = remote_refs;
-                       struct string_list needs_pushing;
+                       struct string_list needs_pushing = STRING_LIST_INIT_DUP;
 
-                       memset(&needs_pushing, 0, sizeof(struct string_list));
-                       needs_pushing.strdup_strings = 1;
                        for (; ref; ref = ref->next)
                                if (!is_null_sha1(ref->new_sha1) &&
                                    find_unpushed_submodules(ref->new_sha1,