Title: [102926] trunk/Source/WebCore
Revision
102926
Author
[email protected]
Date
2011-12-15 05:18:44 -0800 (Thu, 15 Dec 2011)

Log Message

[Qt][WK2] Setting Download as action for navigation request crashes WebProcess
https://bugs.webkit.org/show_bug.cgi?id=74526

Reviewed by Simon Hausmann.

Adding checks for networkcontext and networkAccessManager
and return true in case they don't exist, following the same
logic as if the CookieJar doesn't exist.

* platform/qt/ThirdPartyCookiesQt.cpp:
(WebCore::thirdPartyCookiePolicyPermits):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (102925 => 102926)


--- trunk/Source/WebCore/ChangeLog	2011-12-15 13:16:08 UTC (rev 102925)
+++ trunk/Source/WebCore/ChangeLog	2011-12-15 13:18:44 UTC (rev 102926)
@@ -1,3 +1,17 @@
+2011-12-15  Jesus Sanchez-Palencia  <[email protected]>
+
+        [Qt][WK2] Setting Download as action for navigation request crashes WebProcess
+        https://bugs.webkit.org/show_bug.cgi?id=74526
+
+        Reviewed by Simon Hausmann.
+
+        Adding checks for networkcontext and networkAccessManager
+        and return true in case they don't exist, following the same
+        logic as if the CookieJar doesn't exist.
+
+        * platform/qt/ThirdPartyCookiesQt.cpp:
+        (WebCore::thirdPartyCookiePolicyPermits):
+
 2011-12-14  Tor Arne Vestbø  <[email protected]>
 
         [Qt] Get rid of layering violation in PluginViewQt

Modified: trunk/Source/WebCore/platform/qt/ThirdPartyCookiesQt.cpp (102925 => 102926)


--- trunk/Source/WebCore/platform/qt/ThirdPartyCookiesQt.cpp	2011-12-15 13:16:08 UTC (rev 102925)
+++ trunk/Source/WebCore/platform/qt/ThirdPartyCookiesQt.cpp	2011-12-15 13:18:44 UTC (rev 102926)
@@ -62,6 +62,12 @@
 bool thirdPartyCookiePolicyPermits(NetworkingContext* context, const QUrl& url, const QUrl& firstPartyUrl)
 {
 #if QT_VERSION >= QT_VERSION_CHECK(4, 8, 0)
+    if (!context)
+        return true;
+
+    if (!context->networkAccessManager())
+        return true;
+
     QNetworkCookieJar* jar = context->networkAccessManager()->cookieJar();
     if (!jar)
         return true;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to