From 001dbcfc0b168c5180c452cd3535438ad76a9237 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sat, 8 Sep 2012 07:46:56 +0000 Subject: We no longer use Gestalt(), so there's no need to check for it. We *do*, however, use CFPropertyListCreateWithStream(), so we need to check for it, and, if we're able to use the OS X frameworks at all, use CFPropertyListCreateFromStream() if we don't have CFPropertyListCreateWithStream(). svn path=/trunk/; revision=44812 --- version_info.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'version_info.c') diff --git a/version_info.c b/version_info.c index 887c42fa4b..60021c7705 100644 --- a/version_info.c +++ b/version_info.c @@ -259,9 +259,15 @@ get_os_x_version_info(GString *str) CFRelease(system_version_plist_stream); return FALSE; } +#ifdef HAVE_CFPROPERTYLISTCREATEWITHSTREAM system_version_dict = CFPropertyListCreateWithStream(NULL, system_version_plist_stream, 0, kCFPropertyListImmutable, NULL, NULL); +#else + system_version_dict = CFPropertyListCreateFromStream(NULL, + system_version_plist_stream, 0, kCFPropertyListImmutable, + NULL, NULL); +#endif if (system_version_dict == NULL) return FALSE; if (CFGetTypeID(system_version_dict) != CFDictionaryGetTypeID()) { -- cgit v1.2.3