From 0e06ef535cf522b55e2ba29178a4c188094fa038 Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Tue, 9 Aug 2005 01:20:31 +0000 Subject: [PATCH] Fixed writing to prefpath. --- Source/MacCompatibility.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/MacCompatibility.cpp b/Source/MacCompatibility.cpp index 8e0cae9..e1226b6 100644 --- a/Source/MacCompatibility.cpp +++ b/Source/MacCompatibility.cpp @@ -242,7 +242,7 @@ static int locateCorrectFile(char *buf, const char *mode) snprintf(prefpathfile, len, "%s/%s", prefpath, buf); int rc = locateCorrectCase(prefpathfile, iswriting); /* favor prefpath. */ - if (rc == 0) // found? + if ( (rc == 0) || ((rc == -1) && (iswriting)) ) // found or create? strcpy(buf, prefpathfile); else if ((rc < 0) && (!iswriting)) /* not writing? Try game dir... */ rc = locateCorrectCase(buf, iswriting); -- 2.39.5