Commit 6405ce29 by Reginald McLean

worktree: Added worktree_dir check

Fixes #5280
parent 848c7793
......@@ -259,7 +259,14 @@ int git_worktree_validate(const git_worktree *wt)
wt->commondir_path);
return GIT_ERROR;
}
if (!git_path_exists(wt->worktree_path)) {
git_error_set(GIT_ERROR_WORKTREE,
"worktree directory ('%s') does not exist ",
wt->worktree_path);
return GIT_ERROR;
}
return 0;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment