]> git.ipfire.org Git - thirdparty/git.git/blobdiff - builtin/checkout.c
worktree.c: check whether branch is rebased in another worktree
[thirdparty/git.git] / builtin / checkout.c
index efcbd8f6b5e0b7d551c88c02b6d7d3069a47944d..60417187838ef2e93fcf997dd4b311bcf54c0a15 100644 (file)
@@ -1111,7 +1111,7 @@ static int checkout_branch(struct checkout_opts *opts,
                char *head_ref = resolve_refdup("HEAD", 0, sha1, &flag);
                if (head_ref &&
                    (!(flag & REF_ISSYMREF) || strcmp(head_ref, new->path)))
-                       die_if_checked_out(new->path);
+                       die_if_checked_out(new->path, 1);
                free(head_ref);
        }