From: Daria Brashear Date: Thu, 16 Apr 2015 17:12:05 +0000 (-0400) Subject: osx: update afssettings for yosemite X-Git-Tag: upstream/1.6.13^2~21 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=9e08b24100fc49126b4483279b331f7eb4e745ce;p=packages%2Fo%2Fopenafs.git osx: update afssettings for yosemite handle deprecated functions Reviewed-on: http://gerrit.openafs.org/11836 Tested-by: BuildBot Reviewed-by: Jeffrey Altman (cherry picked from commit ab9bb6363ca95f658764fbb9fb68ec88f89a5b3f) Change-Id: I2ffab98ee422fb9d98a592ccbe2f1efbef1d2197 Reviewed-on: http://gerrit.openafs.org/11859 Tested-by: BuildBot Reviewed-by: Jeffrey Altman Reviewed-by: Stephan Wiesand --- diff --git a/src/platform/DARWIN/afssettings.m b/src/platform/DARWIN/afssettings.m index c5a32bfc2..5b22bf077 100644 --- a/src/platform/DARWIN/afssettings.m +++ b/src/platform/DARWIN/afssettings.m @@ -158,6 +158,10 @@ Setting sysctl_darwin[] = { {@"Darwin80", AFS_SC_DARWIN_80, Node, NULL}, {@"Darwin90", AFS_SC_DARWIN_90, Node, NULL}, {@"Darwin100", AFS_SC_DARWIN_100, Node, NULL}, + {@"Darwin110", AFS_SC_DARWIN_110, Node, NULL}, + {@"Darwin120", AFS_SC_DARWIN_120, Node, NULL}, + {@"Darwin130", AFS_SC_DARWIN_130, Node, NULL}, + {@"Darwin140", AFS_SC_DARWIN_140, Node, NULL}, {NULL, 0, 0, NULL} }; Setting sysctl_first[] = { @@ -173,7 +177,6 @@ main(int argc, char **argv) struct vfsconf vfcp; NSData *plistData; id plist; - NSString *error; NSAutoreleasePool * nspool = [[NSAutoreleasePool alloc] init]; NSString *plistpath = @"/var/db/openafs/etc/config/settings.plist"; int oid[CTL_MAXNAME] = {CTL_VFS}; @@ -182,13 +185,13 @@ main(int argc, char **argv) exit(-1); plistData = [NSData dataWithContentsOfFile: plistpath]; if(plistData) { - plist = [NSPropertyListSerialization propertyListFromData: plistData - mutabilityOption: NSPropertyListImmutable + plist = [NSPropertyListSerialization propertyListWithData: plistData + options: NSPropertyListImmutable format: NULL - errorDescription: &error + error: NULL ]; if (!plist) { - NSLog(@"Error reading plist from file '%s', error = '%s'", [plistpath UTF8String], [error UTF8String]); + NSLog(@"Error reading plist from file '%s'", [plistpath UTF8String]); [nspool release]; return -1; }