aboutsummaryrefslogtreecommitdiff
path: root/src/filemanager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/filemanager.cpp')
-rw-r--r--src/filemanager.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/filemanager.cpp b/src/filemanager.cpp
index 592bada4..005e734b 100644
--- a/src/filemanager.cpp
+++ b/src/filemanager.cpp
@@ -1156,7 +1156,7 @@ std::string pj_context_get_user_writable_directory(PJ_CONTEXT *ctx,
const char *home = getenv("HOME");
if (home) {
#if defined(__MACH__) && defined(__APPLE__)
- path = std::string(home) + "/Library/Logs";
+ path = std::string(home) + "/Library/Application Support";
#else
path = std::string(home) + "/.local/share";
#endif
@@ -1258,13 +1258,11 @@ static const char *proj_lib_name =
nullptr;
#endif
-static bool ignoreUserWritableDirectory() {
+static bool dontReadUserWritableDirectory() {
// Env var mostly for testing purposes and being independent from
// an existing installation
- const char *envVarIgnoreUserWritableDirectory =
- getenv("PROJ_IGNORE_USER_WRITABLE_DIRECTORY");
- return envVarIgnoreUserWritableDirectory != nullptr &&
- envVarIgnoreUserWritableDirectory[0] != '\0';
+ const char *envVar = getenv("PROJ_SKIP_READ_USER_WRITABLE_DIRECTORY");
+ return envVar != nullptr && envVar[0] != '\0';
}
static void *
@@ -1336,7 +1334,7 @@ pj_open_lib_internal(projCtx ctx, const char *name, const char *mode,
}
}
- else if (!ignoreUserWritableDirectory() &&
+ else if (!dontReadUserWritableDirectory() &&
(fid = open_file(
ctx, (pj_context_get_user_writable_directory(ctx, false) +
DIR_CHAR + name)