From 5c9c7297edb967afa88dded927378e1bbb39f3a3 Mon Sep 17 00:00:00 2001 From: Marvin Scholz Date: Fri, 10 Jan 2020 23:48:49 +0100 Subject: [PATCH] Do not use deprecated PHYSFS_getUserDir on macOS Instead use PHYSFS_getPrefDir which does the same than the manual concatenation done before. The organization name argument is required but is not used on macOS. --- desktop_version/src/FileSystemUtils.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/desktop_version/src/FileSystemUtils.cpp b/desktop_version/src/FileSystemUtils.cpp index b024244a..72655713 100644 --- a/desktop_version/src/FileSystemUtils.cpp +++ b/desktop_version/src/FileSystemUtils.cpp @@ -172,8 +172,7 @@ void PLATFORM_getOSDirectory(char* output) strcat(output, "/VVVVVV/"); } #elif defined(__APPLE__) - strcpy(output, PHYSFS_getUserDir()); - strcat(output, "Library/Application Support/VVVVVV/"); + strcpy(output, PHYSFS_getPrefDir("distractionware", "VVVVVV")); #elif defined(_WIN32) SHGetFolderPath(NULL, CSIDL_PERSONAL, NULL, SHGFP_TYPE_CURRENT, output); strcat(output, "\\VVVVVV\\");