mirror of
https://github.com/libgit2/libgit2.git
synced 2026-06-22 06:26:26 +00:00
checkout: add a failing test for refusing a symlinked .gitmodules
We want to reject these as they cause compatibility issues and can lead to git writing to files outside of the repository.
This commit is contained in:
@@ -364,3 +364,10 @@ void test_checkout_nasty__symlink3(void)
|
||||
test_checkout_passes("refs/heads/symlink3", ".git/foobar");
|
||||
}
|
||||
|
||||
void test_checkout_nasty__gitmodules_symlink(void)
|
||||
{
|
||||
cl_repo_set_bool(repo, "core.protectHFS", true);
|
||||
cl_repo_set_bool(repo, "core.protectNTFS", true);
|
||||
|
||||
test_checkout_passes("refs/heads/gitmodules-symlink", ".gitmodules");
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
e30b60b120761f44ebd0f0a7b0e9445ce8e11d68
|
||||
Reference in New Issue
Block a user