]> git.ipfire.org Git - thirdparty/git.git/blobdiff - transport.c
Merge branch 'ag/rebase-i-in-c'
[thirdparty/git.git] / transport.c
index f4ffbd96cb65fdbac3c74d3d60c253bc3a8884f6..5a74b609ffad51752ec91cc93c602f00292288d1 100644 (file)
@@ -1172,7 +1172,7 @@ int transport_push(struct transport *transport,
                                        oid_array_append(&commits,
                                                          &ref->new_oid);
 
-                       if (!push_unpushed_submodules(&the_index,
+                       if (!push_unpushed_submodules(the_repository,
                                                      &commits,
                                                      transport->remote,
                                                      rs,
@@ -1197,7 +1197,7 @@ int transport_push(struct transport *transport,
                                        oid_array_append(&commits,
                                                          &ref->new_oid);
 
-                       if (find_unpushed_submodules(&the_index,
+                       if (find_unpushed_submodules(the_repository,
                                                     &commits,
                                                     transport->remote->name,
                                                     &needs_pushing)) {
@@ -1413,9 +1413,9 @@ static void read_alternate_refs(const char *path,
        fh = xfdopen(cmd.out, "r");
        while (strbuf_getline_lf(&line, fh) != EOF) {
                struct object_id oid;
+               const char *p;
 
-               if (get_oid_hex(line.buf, &oid) ||
-                   line.buf[GIT_SHA1_HEXSZ]) {
+               if (parse_oid_hex(line.buf, &oid, &p) || *p) {
                        warning(_("invalid line while parsing alternate refs: %s"),
                                line.buf);
                        break;