]> git.ipfire.org Git - thirdparty/git.git/blobdiff - dir.c
refs: convert resolve_gitlink_ref to struct object_id
[thirdparty/git.git] / dir.c
diff --git a/dir.c b/dir.c
index a4198ba7fd7f334b947dc7ba7d14b588df1f32e2..f09a31e102232b2c138358585b00635a40227c6e 100644 (file)
--- a/dir.c
+++ b/dir.c
@@ -1391,7 +1391,7 @@ static enum path_treatment treat_directory(struct dir_struct *dir,
                        break;
                if (!(dir->flags & DIR_NO_GITLINKS)) {
                        struct object_id oid;
-                       if (resolve_gitlink_ref(dirname, "HEAD", oid.hash) == 0)
+                       if (resolve_gitlink_ref(dirname, "HEAD", &oid) == 0)
                                return path_untracked;
                }
                return path_recurse;
@@ -2282,7 +2282,7 @@ static int remove_dir_recurse(struct strbuf *path, int flag, int *kept_up)
        struct object_id submodule_head;
 
        if ((flag & REMOVE_DIR_KEEP_NESTED_GIT) &&
-           !resolve_gitlink_ref(path->buf, "HEAD", submodule_head.hash)) {
+           !resolve_gitlink_ref(path->buf, "HEAD", &submodule_head)) {
                /* Do not descend and nuke a nested git work tree. */
                if (kept_up)
                        *kept_up = 1;