summaryrefslogtreecommitdiff
path: root/src/fs_path.c
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@edwardthomson.com>2021-11-01 21:12:23 -0400
committerEdward Thomson <ethomson@edwardthomson.com>2021-11-09 15:17:18 +0000
commit1217c5b232a2343f711ecf4c4ed38211ee6a268a (patch)
treee5fac2ac10e26f42766127da3e742eef4eb942ef /src/fs_path.c
parent622514095fd1d731d35b0d69608911445ba3b0c4 (diff)
downloadlibgit2-1217c5b232a2343f711ecf4c4ed38211ee6a268a.tar.gz
fs_path: remove now-unused validation functions
Diffstat (limited to 'src/fs_path.c')
-rw-r--r--src/fs_path.c46
1 files changed, 0 insertions, 46 deletions
diff --git a/src/fs_path.c b/src/fs_path.c
index 56980148e..957f389cc 100644
--- a/src/fs_path.c
+++ b/src/fs_path.c
@@ -1738,52 +1738,6 @@ int git_fs_path_validate_str_length_with_suffix(
return 0;
}
-#ifdef GIT_WIN32
-GIT_INLINE(bool) should_validate_longpaths(git_repository *repo)
-{
- int longpaths = 0;
-
- if (repo &&
- git_repository__configmap_lookup(&longpaths, repo, GIT_CONFIGMAP_LONGPATHS) < 0)
- longpaths = 0;
-
- return (longpaths == 0);
-}
-
-#else
-
-GIT_INLINE(bool) should_validate_longpaths(git_repository *repo)
-{
- GIT_UNUSED(repo);
-
- return false;
-}
-#endif
-
-int git_fs_path_validate_workdir(git_repository *repo, const char *path)
-{
- if (should_validate_longpaths(repo))
- return git_fs_path_validate_filesystem(path, strlen(path));
-
- return 0;
-}
-
-int git_fs_path_validate_workdir_with_len(
- git_repository *repo,
- const char *path,
- size_t path_len)
-{
- if (should_validate_longpaths(repo))
- return git_fs_path_validate_filesystem(path, path_len);
-
- return 0;
-}
-
-int git_fs_path_validate_workdir_buf(git_repository *repo, git_str *path)
-{
- return git_fs_path_validate_workdir_with_len(repo, path->ptr, path->size);
-}
-
int git_fs_path_normalize_slashes(git_str *out, const char *path)
{
int error;