blob: 0e07371a0d88158e08ccb8dffc57d58ae430cc4f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
Neuter the "safe directory" feature, except for tests.
--- a/setup.c
+++ b/setup.c
@@ -1316,7 +1316,9 @@ static int ensure_valid_ownership(const char *gitfile,
git_protected_config(safe_directory_cb, &data);
free(data.path);
- return data.is_safe;
+ if (git_env_bool("GIT_TEST_ASSUME_DIFFERENT_OWNER", 0))
+ return data.is_safe;
+ return 1;
}
void die_upon_dubious_ownership(const char *gitfile, const char *worktree,
|