Title: [152950] trunk/Source/WebKit2
Revision
152950
Author
[email protected]
Date
2013-07-21 11:55:37 -0700 (Sun, 21 Jul 2013)

Log Message

Java Updater not launched on Lion and Mountain Lion
https://bugs.webkit.org/show_bug.cgi?id=118953
<rdar://problem/14496721>

Reviewed by Sam Weinig.

On Lion and Mountain Lion, -[NSURL isEqual:] will return NO for two file URLs if one of
them has "localhost" specified, even if the paths are otherwise equal. Work around this by
comparing the paths directly.

* UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
(WebKit::isJavaUpdaterURL):

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (152949 => 152950)


--- trunk/Source/WebKit2/ChangeLog	2013-07-21 01:45:08 UTC (rev 152949)
+++ trunk/Source/WebKit2/ChangeLog	2013-07-21 18:55:37 UTC (rev 152950)
@@ -1,3 +1,18 @@
+2013-07-21  Anders Carlsson  <[email protected]>
+
+        Java Updater not launched on Lion and Mountain Lion
+        https://bugs.webkit.org/show_bug.cgi?id=118953
+        <rdar://problem/14496721>
+
+        Reviewed by Sam Weinig.
+
+        On Lion and Mountain Lion, -[NSURL isEqual:] will return NO for two file URLs if one of
+        them has "localhost" specified, even if the paths are otherwise equal. Work around this by
+        comparing the paths directly.
+
+        * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
+        (WebKit::isJavaUpdaterURL):
+
 2013-07-19  Morten Stenshorne  <[email protected]>
 
         [GTK] Need a way to enable region based columns from the command line

Modified: trunk/Source/WebKit2/UIProcess/Plugins/mac/PluginProcessProxyMac.mm (152949 => 152950)


--- trunk/Source/WebKit2/UIProcess/Plugins/mac/PluginProcessProxyMac.mm	2013-07-21 01:45:08 UTC (rev 152949)
+++ trunk/Source/WebKit2/UIProcess/Plugins/mac/PluginProcessProxyMac.mm	2013-07-21 18:55:37 UTC (rev 152950)
@@ -405,9 +405,12 @@
 
 static bool isJavaUpdaterURL(const PluginProcessAttributes& pluginProcessAttributes, const String& urlString)
 {
-    NSURL *javaUpdaterURL = [NSURL fileURLWithPathComponents:[NSArray arrayWithObjects:(NSString *)pluginProcessAttributes.moduleInfo.path, @"Contents/Resources/Java Updater.app", nil]];
+    NSURL *url = "" URLWithString:urlString];
+    if (![url isFileURL])
+        return false;
 
-    return [[NSURL URLWithString:urlString] isEqual:javaUpdaterURL];
+    NSString *javaUpdaterPath = [NSString pathWithComponents:[NSArray arrayWithObjects:(NSString *)pluginProcessAttributes.moduleInfo.path, @"Contents/Resources/Java Updater.app", nil]];
+    return [url.path isEqualToString:javaUpdaterPath];
 }
 
 static bool shouldLaunchApplicationAtURL(const PluginProcessAttributes& pluginProcessAttributes, const String& urlString)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to