From 8ddaa855bc94e4e322e546663837cab074224c9d Mon Sep 17 00:00:00 2001 From: Josh Aas Date: Fri, 7 Jan 2011 07:47:41 -0500 Subject: [PATCH] Bug 611296: Fix bug that caused the Quicktime plugin to fail to load for some Mac OS X users. Don't require that the MIME plist locale match the current locale. r=sgreenlay a=blocking2.0betaN+ --- modules/plugin/base/src/nsPluginHost.cpp | 3 ++- modules/plugin/base/src/nsPluginsDirDarwin.cpp | 17 +---------------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/modules/plugin/base/src/nsPluginHost.cpp b/modules/plugin/base/src/nsPluginHost.cpp index 1a60951f235..dd8d6d2e7f5 100644 --- a/modules/plugin/base/src/nsPluginHost.cpp +++ b/modules/plugin/base/src/nsPluginHost.cpp @@ -192,8 +192,9 @@ using mozilla::TimeStamp; // 0.11 file name and full path fields now store expected values on all platforms, bug 488181 // 0.12 force refresh due to quicktime pdf claim fix, bug 611197 // 0.13 add architecture and list of invalid plugins, bug 616271 +// 0.14 force refresh due to locale comparison fix, bug 611296 // The current plugin registry version (and the maximum version we know how to read) -static const char *kPluginRegistryVersion = "0.13"; +static const char *kPluginRegistryVersion = "0.14"; // The minimum registry version we know how to read static const char *kMinimumRegistryVersion = "0.9"; diff --git a/modules/plugin/base/src/nsPluginsDirDarwin.cpp b/modules/plugin/base/src/nsPluginsDirDarwin.cpp index 3c7486a4043..3387c1bd47a 100644 --- a/modules/plugin/base/src/nsPluginsDirDarwin.cpp +++ b/modules/plugin/base/src/nsPluginsDirDarwin.cpp @@ -212,22 +212,7 @@ static CFDictionaryRef ParsePlistForMIMETypesFilename(CFBundleRef bundle) if (::CFGetTypeID(propertyList) != ::CFDictionaryGetTypeID()) { return NULL; } - - CFTypeRef localizedName = ::CFDictionaryGetValue(static_cast(propertyList), CFSTR("WebPluginLocalizationName")); - if (!localizedName || ::CFGetTypeID(localizedName) != ::CFStringGetTypeID()) { - return NULL; - } - - CFLocaleRef currentLocale = ::CFLocaleCopyCurrent(); - if (!currentLocale) { - return NULL; - } - - AutoCFTypeObject currentLocaleAutorelease(currentLocale); - if (::CFStringCompare(static_cast(localizedName), ::CFLocaleGetIdentifier(currentLocale), 0) != kCFCompareEqualTo) { - return NULL; - } - + CFTypeRef mimeTypes = ::CFDictionaryGetValue(static_cast(propertyList), CFSTR("WebPluginMIMETypes")); if (!mimeTypes || ::CFGetTypeID(mimeTypes) != ::CFDictionaryGetTypeID() || ::CFDictionaryGetCount(static_cast(mimeTypes)) == 0) { return NULL;