submodule--helper: replace connect-gitdir-workingtree by ensure-core-worktree
[gitweb.git] / wt-status.c
index fadbed0de9710643ac595f551f2897133b05f8c9..6bf2fdbab67fffb4c9ef451b61bbc7ca8f6780ea 100644 (file)
@@ -1489,7 +1489,7 @@ static void wt_status_get_detached_from(struct wt_status_state *state)
            /* sha1 is a commit? match without further lookup */
            (!oidcmp(&cb.noid, &oid) ||
             /* perhaps sha1 is a tag, try to dereference to a commit */
-            ((commit = lookup_commit_reference_gently(&oid, 1)) != NULL &&
+            ((commit = lookup_commit_reference_gently(the_repository, &oid, 1)) != NULL &&
              !oidcmp(&cb.noid, &commit->object.oid)))) {
                const char *from = ref;
                if (!skip_prefix(from, "refs/tags/", &from))
@@ -2347,7 +2347,7 @@ int has_uncommitted_changes(int ignore_submodules)
                 * We have no head (or it's corrupt); use the empty tree,
                 * which will complain if the index is non-empty.
                 */
-               struct tree *tree = lookup_tree(the_hash_algo->empty_tree);
+               struct tree *tree = lookup_tree(the_repository, the_hash_algo->empty_tree);
                add_pending_object(&rev_info, &tree->object, "");
        }