apple: Patched to compile with older (mac 10.7) SDKs (thanks, Ken and Ryan!).

This commit is contained in:
Ryan C. Gordon 2018-03-24 00:19:59 -04:00
parent 0bad12d401
commit 7394c07d6b
1 changed files with 1 additions and 1 deletions

View File

@ -50,7 +50,7 @@ char *__PHYSFS_platformCalcPrefDir(const char *org, const char *app)
{
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSApplicationSupportDirectory, NSUserDomainMask, TRUE);
BAIL_IF(!paths, PHYSFS_ERR_OS_ERROR, NULL);
NSString *path = (NSString *) paths[0];
NSString *path = (NSString *) [paths objectAtIndex:0];
BAIL_IF(!path, PHYSFS_ERR_OS_ERROR, NULL);
size_t len = [path lengthOfBytesUsingEncoding:NSUTF8StringEncoding];
const size_t applen = strlen(app);