<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[190611] trunk</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/190611">190611</a></dd>
<dt>Author</dt> <dd>commit-queue@webkit.org</dd>
<dt>Date</dt> <dd>2015-10-06 01:18:08 -0700 (Tue, 06 Oct 2015)</dd>
</dl>
<h3>Log Message</h3>
<pre>Report error when main resource is blocked by content blocker
https://bugs.webkit.org/show_bug.cgi?id=149719
rdar://problem/21970595
Patch by Alex Christensen <achristensen@webkit.org> on 2015-10-06
Reviewed by Brady Eidson.
Source/WebCore:
Test: http/tests/contentextensions/main-resource.html
* English.lproj/Localizable.strings:
* contentextensions/ContentExtensionActions.h:
* contentextensions/ContentExtensionError.h:
(WebCore::ContentExtensions::make_error_code):
* contentextensions/ContentExtensionsBackend.cpp:
(WebCore::ContentExtensions::ContentExtensionsBackend::globalDisplayNoneStyleSheet):
(WebCore::ContentExtensions::ContentExtensionsBackend::processContentExtensionRulesForLoad):
Instead of nulling out the ResourceRequest, processContentExtensionRulesForLoad
now returns a status indicating whether the request should be blocked.
This is needed because the DocumentLoader needs a CachedResource with an error representing the blocking
(WebCore::ContentExtensions::ContentExtensionsBackend::displayNoneCSSRule):
* contentextensions/ContentExtensionsBackend.h:
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::loadResource):
* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::startLoadingMainResource):
Dispatch an error if the resource is blocked by a content blocker.
* loader/EmptyClients.h:
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::loadResourceSynchronously):
(WebCore::FrameLoader::cancelledError):
(WebCore::FrameLoader::blockedByContentBlockerError):
(WebCore::FrameLoader::connectionProperties):
* loader/FrameLoader.h:
* loader/FrameLoaderClient.h:
* loader/ResourceLoader.cpp:
(WebCore::ResourceLoader::willSendRequestInternal):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::requestResource):
* page/UserContentController.cpp:
(WebCore::UserContentController::removeAllUserContentExtensions):
(WebCore::UserContentController::processContentExtensionRulesForLoad):
(WebCore::UserContentController::actionsForResourceLoad):
* page/UserContentController.h:
* platform/efl/ErrorsEfl.cpp:
(WebCore::blockedError):
(WebCore::blockedByContentBlockerError):
(WebCore::cannotShowURLError):
* platform/efl/ErrorsEfl.h:
* platform/gtk/ErrorsGtk.cpp:
(WebCore::blockedError):
(WebCore::blockedByContentBlockerError):
(WebCore::cannotShowURLError):
* platform/gtk/ErrorsGtk.h:
Source/WebKit/mac:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::blockedError):
(WebFrameLoaderClient::blockedByContentBlockerError):
(WebFrameLoaderClient::cannotShowURLError):
Add blockedByContentBlockerError so WebFrameLoaderClient is not an abstract class,
but it should be unused because content blockers are not enabled on WK1.
Source/WebKit/win:
* WebCoreSupport/WebFrameLoaderClient.cpp:
(WebFrameLoaderClient::blockedError):
(WebFrameLoaderClient::blockedByContentBlockerError):
(WebFrameLoaderClient::cannotShowURLError):
* WebCoreSupport/WebFrameLoaderClient.h:
Added stub that should never be used.
Source/WebKit2:
* Shared/API/c/WKErrorRef.h:
* WebProcess/WebCoreSupport/WebErrors.h:
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::blockedError):
(WebKit::WebFrameLoaderClient::blockedByContentBlockerError):
(WebKit::WebFrameLoaderClient::cannotShowURLError):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
* WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp:
(WebKit::blockedError):
(WebKit::blockedByContentBlockerError):
(WebKit::cannotShowURLError):
* WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp:
(WebKit::blockedError):
(WebKit::blockedByContentBlockerError):
(WebKit::cannotShowURLError):
* WebProcess/WebCoreSupport/mac/WebErrorsMac.mm:
(WebKit::blockedError):
(WebKit::blockedByContentBlockerError):
(WebKit::cannotShowURLError):
Make a new error type for loads that were blocked by a content blocker.
LayoutTests:
* http/tests/contentextensions/main-resource-expected.txt: Added.
* http/tests/contentextensions/main-resource.html: Added.
* http/tests/contentextensions/main-resource.html.json: Added.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreEnglishlprojLocalizablestrings">trunk/Source/WebCore/English.lproj/Localizable.strings</a></li>
<li><a href="#trunkSourceWebCorecontentextensionsContentExtensionActionsh">trunk/Source/WebCore/contentextensions/ContentExtensionActions.h</a></li>
<li><a href="#trunkSourceWebCorecontentextensionsContentExtensionErrorcpp">trunk/Source/WebCore/contentextensions/ContentExtensionError.cpp</a></li>
<li><a href="#trunkSourceWebCorecontentextensionsContentExtensionErrorh">trunk/Source/WebCore/contentextensions/ContentExtensionError.h</a></li>
<li><a href="#trunkSourceWebCorecontentextensionsContentExtensionsBackendcpp">trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.cpp</a></li>
<li><a href="#trunkSourceWebCorecontentextensionsContentExtensionsBackendh">trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.h</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLMediaElementcpp">trunk/Source/WebCore/html/HTMLMediaElement.cpp</a></li>
<li><a href="#trunkSourceWebCoreloaderDocumentLoadercpp">trunk/Source/WebCore/loader/DocumentLoader.cpp</a></li>
<li><a href="#trunkSourceWebCoreloaderEmptyClientsh">trunk/Source/WebCore/loader/EmptyClients.h</a></li>
<li><a href="#trunkSourceWebCoreloaderFrameLoadercpp">trunk/Source/WebCore/loader/FrameLoader.cpp</a></li>
<li><a href="#trunkSourceWebCoreloaderFrameLoaderh">trunk/Source/WebCore/loader/FrameLoader.h</a></li>
<li><a href="#trunkSourceWebCoreloaderFrameLoaderClienth">trunk/Source/WebCore/loader/FrameLoaderClient.h</a></li>
<li><a href="#trunkSourceWebCoreloaderResourceLoadercpp">trunk/Source/WebCore/loader/ResourceLoader.cpp</a></li>
<li><a href="#trunkSourceWebCoreloadercacheCachedResourceLoadercpp">trunk/Source/WebCore/loader/cache/CachedResourceLoader.cpp</a></li>
<li><a href="#trunkSourceWebCorepageUserContentControllercpp">trunk/Source/WebCore/page/UserContentController.cpp</a></li>
<li><a href="#trunkSourceWebCorepageUserContentControllerh">trunk/Source/WebCore/page/UserContentController.h</a></li>
<li><a href="#trunkSourceWebCoreplatformeflErrorsEflcpp">trunk/Source/WebCore/platform/efl/ErrorsEfl.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformeflErrorsEflh">trunk/Source/WebCore/platform/efl/ErrorsEfl.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgtkErrorsGtkcpp">trunk/Source/WebCore/platform/gtk/ErrorsGtk.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgtkErrorsGtkh">trunk/Source/WebCore/platform/gtk/ErrorsGtk.h</a></li>
<li><a href="#trunkSourceWebKitmacChangeLog">trunk/Source/WebKit/mac/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClienth">trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h</a></li>
<li><a href="#trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClientmm">trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm</a></li>
<li><a href="#trunkSourceWebKitwinChangeLog">trunk/Source/WebKit/win/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitwinWebCoreSupportWebFrameLoaderClientcpp">trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.cpp</a></li>
<li><a href="#trunkSourceWebKitwinWebCoreSupportWebFrameLoaderClienth">trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.h</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2SharedAPIcWKErrorRefh">trunk/Source/WebKit2/Shared/API/c/WKErrorRef.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebErrorsh">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebErrors.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClientcpp">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClienth">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupporteflWebErrorsEflcpp">trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportgtkWebErrorsGtkcpp">trunk/Source/WebKit2/WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportmacWebErrorsMacmm">trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm</a></li>
</ul>
<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestshttptestscontentextensionsmainresourceexpectedtxt">trunk/LayoutTests/http/tests/contentextensions/main-resource-expected.txt</a></li>
<li><a href="#trunkLayoutTestshttptestscontentextensionsmainresourcehtml">trunk/LayoutTests/http/tests/contentextensions/main-resource.html</a></li>
<li><a href="#trunkLayoutTestshttptestscontentextensionsmainresourcehtmljson">trunk/LayoutTests/http/tests/contentextensions/main-resource.html.json</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/LayoutTests/ChangeLog        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1,3 +1,15 @@
</span><ins>+2015-10-06 Alex Christensen <achristensen@webkit.org>
+
+ Report error when main resource is blocked by content blocker
+ https://bugs.webkit.org/show_bug.cgi?id=149719
+ rdar://problem/21970595
+
+ Reviewed by Brady Eidson.
+
+ * http/tests/contentextensions/main-resource-expected.txt: Added.
+ * http/tests/contentextensions/main-resource.html: Added.
+ * http/tests/contentextensions/main-resource.html.json: Added.
+
</ins><span class="cx"> 2015-10-05 Byung Jun Kim <bj1987.kim@samsung.com>
</span><span class="cx">
</span><span class="cx"> Unreviewed EFL Gardening
</span></span></pre></div>
<a id="trunkLayoutTestshttptestscontentextensionsmainresourceexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/http/tests/contentextensions/main-resource-expected.txt (0 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/http/tests/contentextensions/main-resource-expected.txt         (rev 0)
+++ trunk/LayoutTests/http/tests/contentextensions/main-resource-expected.txt        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -0,0 +1,5 @@
</span><ins>+http://127.0.0.1:8000/contentextensions/main-resource.html - didFinishLoading
+CONSOLE MESSAGE: Content blocker prevented frame displaying http://127.0.0.1:8000/contentextensions/resources/should-not-load.html from loading a resource from http://127.0.0.1:8000/contentextensions/resources/should-not-load.html
+http://127.0.0.1:8000/contentextensions/resources/should-not-load.html - didFailLoadingWithError: <NSError domain WebKitErrorDomain, code 104, failing URL "http://127.0.0.1:8000/contentextensions/resources/should-not-load.html">
+http://127.0.0.1:8000/contentextensions/resources/should-not-load.html - didFinishLoading
+
</ins></span></pre></div>
<a id="trunkLayoutTestshttptestscontentextensionsmainresourcehtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/http/tests/contentextensions/main-resource.html (0 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/http/tests/contentextensions/main-resource.html         (rev 0)
+++ trunk/LayoutTests/http/tests/contentextensions/main-resource.html        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+<script>
+if (window.testRunner) {
+ testRunner.dumpResourceLoadCallbacks();
+ testRunner.dumpAsText();
+ testRunner.queueLoad("resources/should-not-load.html");
+}
+</script>
</ins></span></pre></div>
<a id="trunkLayoutTestshttptestscontentextensionsmainresourcehtmljson"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/http/tests/contentextensions/main-resource.html.json (0 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/http/tests/contentextensions/main-resource.html.json         (rev 0)
+++ trunk/LayoutTests/http/tests/contentextensions/main-resource.html.json        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -0,0 +1,10 @@
</span><ins>+[
+ {
+ "action": {
+ "type": "block"
+ },
+ "trigger": {
+ "url-filter": "should-not-load"
+ }
+ }
+]
</ins></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/ChangeLog        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1,3 +1,58 @@
</span><ins>+2015-10-06 Alex Christensen <achristensen@webkit.org>
+
+ Report error when main resource is blocked by content blocker
+ https://bugs.webkit.org/show_bug.cgi?id=149719
+ rdar://problem/21970595
+
+ Reviewed by Brady Eidson.
+
+ Test: http/tests/contentextensions/main-resource.html
+
+ * English.lproj/Localizable.strings:
+ * contentextensions/ContentExtensionActions.h:
+ * contentextensions/ContentExtensionError.h:
+ (WebCore::ContentExtensions::make_error_code):
+ * contentextensions/ContentExtensionsBackend.cpp:
+ (WebCore::ContentExtensions::ContentExtensionsBackend::globalDisplayNoneStyleSheet):
+ (WebCore::ContentExtensions::ContentExtensionsBackend::processContentExtensionRulesForLoad):
+ Instead of nulling out the ResourceRequest, processContentExtensionRulesForLoad
+ now returns a status indicating whether the request should be blocked.
+ This is needed because the DocumentLoader needs a CachedResource with an error representing the blocking
+ (WebCore::ContentExtensions::ContentExtensionsBackend::displayNoneCSSRule):
+ * contentextensions/ContentExtensionsBackend.h:
+ * html/HTMLMediaElement.cpp:
+ (WebCore::HTMLMediaElement::loadResource):
+ * loader/DocumentLoader.cpp:
+ (WebCore::DocumentLoader::startLoadingMainResource):
+ Dispatch an error if the resource is blocked by a content blocker.
+ * loader/EmptyClients.h:
+ * loader/FrameLoader.cpp:
+ (WebCore::FrameLoader::loadResourceSynchronously):
+ (WebCore::FrameLoader::cancelledError):
+ (WebCore::FrameLoader::blockedByContentBlockerError):
+ (WebCore::FrameLoader::connectionProperties):
+ * loader/FrameLoader.h:
+ * loader/FrameLoaderClient.h:
+ * loader/ResourceLoader.cpp:
+ (WebCore::ResourceLoader::willSendRequestInternal):
+ * loader/cache/CachedResourceLoader.cpp:
+ (WebCore::CachedResourceLoader::requestResource):
+ * page/UserContentController.cpp:
+ (WebCore::UserContentController::removeAllUserContentExtensions):
+ (WebCore::UserContentController::processContentExtensionRulesForLoad):
+ (WebCore::UserContentController::actionsForResourceLoad):
+ * page/UserContentController.h:
+ * platform/efl/ErrorsEfl.cpp:
+ (WebCore::blockedError):
+ (WebCore::blockedByContentBlockerError):
+ (WebCore::cannotShowURLError):
+ * platform/efl/ErrorsEfl.h:
+ * platform/gtk/ErrorsGtk.cpp:
+ (WebCore::blockedError):
+ (WebCore::blockedByContentBlockerError):
+ (WebCore::cannotShowURLError):
+ * platform/gtk/ErrorsGtk.h:
+
</ins><span class="cx"> 2015-10-06 Xabier Rodriguez Calvar <calvaris@igalia.com>
</span><span class="cx">
</span><span class="cx"> JSBuiltinConstructor must always add builtin header
</span></span></pre></div>
<a id="trunkSourceWebCoreEnglishlprojLocalizablestrings"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/English.lproj/Localizable.strings (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/English.lproj/Localizable.strings        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/English.lproj/Localizable.strings        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -592,6 +592,9 @@
</span><span class="cx"> /* WebKitErrorCannotShowURL description */
</span><span class="cx"> "The URL can’t be shown" = "The URL can’t be shown";
</span><span class="cx">
</span><ins>+/* WebKitErrorBlockedByContentBlocker description */
+"The URL was blocked by a content blocker" = "The URL was blocked by a content blocker";
+
</ins><span class="cx"> /* WKErrorWebViewInvalidated description */
</span><span class="cx"> "The WKWebView was invalidated" = "The WKWebView was invalidated";
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorecontentextensionsContentExtensionActionsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/contentextensions/ContentExtensionActions.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/contentextensions/ContentExtensionActions.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/contentextensions/ContentExtensionActions.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -43,6 +43,11 @@
</span><span class="cx"> InvalidAction,
</span><span class="cx"> };
</span><span class="cx">
</span><ins>+enum class BlockedStatus {
+ Blocked,
+ NotBlocked,
+};
+
</ins><span class="cx"> } // namespace ContentExtensions
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorecontentextensionsContentExtensionErrorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/contentextensions/ContentExtensionError.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/contentextensions/ContentExtensionError.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/contentextensions/ContentExtensionError.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -34,6 +34,8 @@
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> namespace ContentExtensions {
</span><span class="cx">
</span><ins>+const char* WebKitContentBlockerDomain = "WebKitContentBlockerDomain";
+
</ins><span class="cx"> const std::error_category& contentExtensionErrorCategory()
</span><span class="cx"> {
</span><span class="cx"> class ContentExtensionErrorCategory : public std::error_category {
</span></span></pre></div>
<a id="trunkSourceWebCorecontentextensionsContentExtensionErrorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/contentextensions/ContentExtensionError.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/contentextensions/ContentExtensionError.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/contentextensions/ContentExtensionError.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -60,6 +60,8 @@
</span><span class="cx"> JSONInvalidRegex,
</span><span class="cx"> };
</span><span class="cx">
</span><ins>+extern const char* WebKitContentBlockerDomain;
+
</ins><span class="cx"> WEBCORE_EXPORT const std::error_category& contentExtensionErrorCategory();
</span><span class="cx">
</span><span class="cx"> inline std::error_code make_error_code(ContentExtensionError error)
</span></span></pre></div>
<a id="trunkSourceWebCorecontentextensionsContentExtensionsBackendcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -145,7 +145,7 @@
</span><span class="cx"> return contentExtension ? contentExtension->globalDisplayNoneStyleSheet() : nullptr;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void ContentExtensionsBackend::processContentExtensionRulesForLoad(ResourceRequest& request, ResourceType resourceType, DocumentLoader& initiatingDocumentLoader)
</del><ins>+BlockedStatus ContentExtensionsBackend::processContentExtensionRulesForLoad(ResourceRequest& request, ResourceType resourceType, DocumentLoader& initiatingDocumentLoader)
</ins><span class="cx"> {
</span><span class="cx"> Document* currentDocument = nullptr;
</span><span class="cx"> URL mainDocumentURL;
</span><span class="lines">@@ -198,8 +198,9 @@
</span><span class="cx"> if (willBlockLoad) {
</span><span class="cx"> if (currentDocument)
</span><span class="cx"> currentDocument->addConsoleMessage(MessageSource::ContentBlocker, MessageLevel::Info, makeString("Content blocker prevented frame displaying ", mainDocumentURL.string(), " from loading a resource from ", request.url().string()));
</span><del>- request = ResourceRequest();
</del><ins>+ return BlockedStatus::Blocked;
</ins><span class="cx"> }
</span><ins>+ return BlockedStatus::NotBlocked;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> const String& ContentExtensionsBackend::displayNoneCSSRule()
</span></span></pre></div>
<a id="trunkSourceWebCorecontentextensionsContentExtensionsBackendh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/contentextensions/ContentExtensionsBackend.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -65,7 +65,7 @@
</span><span class="cx"> WEBCORE_EXPORT Vector<Action> actionsForResourceLoad(const ResourceLoadInfo&) const;
</span><span class="cx"> WEBCORE_EXPORT StyleSheetContents* globalDisplayNoneStyleSheet(const String& identifier) const;
</span><span class="cx">
</span><del>- void processContentExtensionRulesForLoad(ResourceRequest&, ResourceType, DocumentLoader& initiatingDocumentLoader);
</del><ins>+ BlockedStatus processContentExtensionRulesForLoad(ResourceRequest&, ResourceType, DocumentLoader& initiatingDocumentLoader);
</ins><span class="cx">
</span><span class="cx"> static const String& displayNoneCSSRule();
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLMediaElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLMediaElement.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLMediaElement.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/html/HTMLMediaElement.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1225,10 +1225,8 @@
</span><span class="cx"> ResourceRequest request(url);
</span><span class="cx"> DocumentLoader* documentLoader = frame->loader().documentLoader();
</span><span class="cx">
</span><del>- if (page->userContentController() && documentLoader)
- page->userContentController()->processContentExtensionRulesForLoad(request, ResourceType::Media, *documentLoader);
-
- if (request.isNull()) {
</del><ins>+ if (page->userContentController() && documentLoader && page->userContentController()->processContentExtensionRulesForLoad(request, ResourceType::Media, *documentLoader) == ContentExtensions::BlockedStatus::Blocked) {
+ request = { };
</ins><span class="cx"> mediaLoadingFailed(MediaPlayer::FormatError);
</span><span class="cx"> return;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderDocumentLoadercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/DocumentLoader.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/DocumentLoader.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/loader/DocumentLoader.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -35,6 +35,7 @@
</span><span class="cx"> #include "CachedPage.h"
</span><span class="cx"> #include "CachedRawResource.h"
</span><span class="cx"> #include "CachedResourceLoader.h"
</span><ins>+#include "ContentExtensionError.h"
</ins><span class="cx"> #include "DOMWindow.h"
</span><span class="cx"> #include "Document.h"
</span><span class="cx"> #include "DocumentParser.h"
</span><span class="lines">@@ -1425,7 +1426,7 @@
</span><span class="cx">
</span><span class="cx"> m_applicationCacheHost->maybeLoadMainResource(m_request, m_substituteData);
</span><span class="cx">
</span><del>- if (m_substituteData.isValid()) {
</del><ins>+ if (m_substituteData.isValid() && m_frame->page()) {
</ins><span class="cx"> m_identifierForLoadWithoutResourceLoader = m_frame->page()->progress().createUniqueIdentifier();
</span><span class="cx"> frameLoader()->notifier().assignIdentifierToInitialRequest(m_identifierForLoadWithoutResourceLoader, this, m_request);
</span><span class="cx"> frameLoader()->notifier().dispatchWillSendRequest(this, m_identifierForLoadWithoutResourceLoader, m_request, ResourceResponse());
</span><span class="lines">@@ -1442,6 +1443,16 @@
</span><span class="cx"> CachedResourceRequest cachedResourceRequest(request, mainResourceLoadOptions);
</span><span class="cx"> cachedResourceRequest.setInitiator(*this);
</span><span class="cx"> m_mainResource = m_cachedResourceLoader->requestMainResource(cachedResourceRequest);
</span><ins>+
+#if ENABLE(CONTENT_EXTENSIONS)
+ if (m_mainResource && m_mainResource->errorOccurred() && m_frame->page() && m_mainResource->resourceError().domain() == ContentExtensions::WebKitContentBlockerDomain) {
+ m_identifierForLoadWithoutResourceLoader = m_frame->page()->progress().createUniqueIdentifier();
+ frameLoader()->notifier().assignIdentifierToInitialRequest(m_identifierForLoadWithoutResourceLoader, this, request);
+ frameLoader()->notifier().dispatchDidFailLoading(this, m_identifierForLoadWithoutResourceLoader, frameLoader()->blockedByContentBlockerError(m_request));
+ m_mainResource = nullptr;
+ }
+#endif
+
</ins><span class="cx"> if (!m_mainResource) {
</span><span class="cx"> setRequest(ResourceRequest());
</span><span class="cx"> // If the load was aborted by clearing m_request, it's possible the ApplicationCacheHost
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderEmptyClientsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/EmptyClients.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/EmptyClients.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/loader/EmptyClients.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -322,6 +322,7 @@
</span><span class="cx">
</span><span class="cx"> virtual ResourceError cancelledError(const ResourceRequest&) override { ResourceError error("", 0, "", ""); error.setIsCancellation(true); return error; }
</span><span class="cx"> virtual ResourceError blockedError(const ResourceRequest&) override { return ResourceError("", 0, "", ""); }
</span><ins>+ virtual ResourceError blockedByContentBlockerError(const ResourceRequest&) override { return ResourceError("", 0, "", ""); }
</ins><span class="cx"> virtual ResourceError cannotShowURLError(const ResourceRequest&) override { return ResourceError("", 0, "", ""); }
</span><span class="cx"> virtual ResourceError interruptedForPolicyChangeError(const ResourceRequest&) override { return ResourceError("", 0, "", ""); }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderFrameLoadercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/FrameLoader.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/FrameLoader.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/loader/FrameLoader.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -2707,18 +2707,16 @@
</span><span class="cx">
</span><span class="cx"> #if ENABLE(CONTENT_EXTENSIONS)
</span><span class="cx"> if (error.isNull()) {
</span><del>- if (m_documentLoader) {
- if (auto* page = m_frame.page()) {
- if (auto* controller = page->userContentController())
- controller->processContentExtensionRulesForLoad(newRequest, ResourceType::Raw, *m_documentLoader);
</del><ins>+ if (auto* page = m_frame.page()) {
+ if (auto* controller = page->userContentController()) {
+ if (m_documentLoader && controller->processContentExtensionRulesForLoad(newRequest, ResourceType::Raw, *m_documentLoader) == ContentExtensions::BlockedStatus::Blocked) {
+ newRequest = { };
+ error = ResourceError(errorDomainWebKitInternal, 0, initialRequest.url().string(), emptyString());
+ response = { };
+ data = nullptr;
+ }
</ins><span class="cx"> }
</span><span class="cx"> }
</span><del>-
- if (newRequest.isNull()) {
- error = ResourceError(errorDomainWebKitInternal, 0, initialRequest.url().string(), emptyString());
- response = ResourceResponse();
- data = nullptr;
- }
</del><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="cx">
</span><span class="lines">@@ -3324,6 +3322,11 @@
</span><span class="cx"> return error;
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError FrameLoader::blockedByContentBlockerError(const ResourceRequest& request) const
+{
+ return m_client.blockedByContentBlockerError(request);
+}
+
</ins><span class="cx"> #if PLATFORM(IOS)
</span><span class="cx"> RetainPtr<CFDictionaryRef> FrameLoader::connectionProperties(ResourceLoader* loader)
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderFrameLoaderh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/FrameLoader.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/FrameLoader.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/loader/FrameLoader.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -170,6 +170,7 @@
</span><span class="cx"> void handleFallbackContent();
</span><span class="cx">
</span><span class="cx"> WEBCORE_EXPORT ResourceError cancelledError(const ResourceRequest&) const;
</span><ins>+ WEBCORE_EXPORT ResourceError blockedByContentBlockerError(const ResourceRequest&) const;
</ins><span class="cx">
</span><span class="cx"> bool isHostedByObjectElement() const;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderFrameLoaderClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/FrameLoaderClient.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/FrameLoaderClient.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/loader/FrameLoaderClient.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -228,6 +228,7 @@
</span><span class="cx">
</span><span class="cx"> virtual ResourceError cancelledError(const ResourceRequest&) = 0;
</span><span class="cx"> virtual ResourceError blockedError(const ResourceRequest&) = 0;
</span><ins>+ virtual ResourceError blockedByContentBlockerError(const ResourceRequest&) = 0;
</ins><span class="cx"> virtual ResourceError cannotShowURLError(const ResourceRequest&) = 0;
</span><span class="cx"> virtual ResourceError interruptedForPolicyChangeError(const ResourceRequest&) = 0;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderResourceLoadercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/ResourceLoader.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/ResourceLoader.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/loader/ResourceLoader.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -341,8 +341,8 @@
</span><span class="cx"> Page* page = frameLoader()->frame().page();
</span><span class="cx"> if (page && m_documentLoader) {
</span><span class="cx"> auto* userContentController = page->userContentController();
</span><del>- if (userContentController)
- userContentController->processContentExtensionRulesForLoad(request, m_resourceType, *m_documentLoader);
</del><ins>+ if (userContentController && userContentController->processContentExtensionRulesForLoad(request, m_resourceType, *m_documentLoader) == ContentExtensions::BlockedStatus::Blocked)
+ request = { };
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="trunkSourceWebCoreloadercacheCachedResourceLoadercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/cache/CachedResourceLoader.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/cache/CachedResourceLoader.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/loader/cache/CachedResourceLoader.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -38,6 +38,7 @@
</span><span class="cx"> #include "CachedXSLStyleSheet.h"
</span><span class="cx"> #include "Chrome.h"
</span><span class="cx"> #include "ChromeClient.h"
</span><ins>+#include "ContentExtensionError.h"
</ins><span class="cx"> #include "ContentExtensionRule.h"
</span><span class="cx"> #include "ContentSecurityPolicy.h"
</span><span class="cx"> #include "DOMWindow.h"
</span><span class="lines">@@ -51,6 +52,7 @@
</span><span class="cx"> #include "HTMLElement.h"
</span><span class="cx"> #include "HTMLFrameOwnerElement.h"
</span><span class="cx"> #include "LoaderStrategy.h"
</span><ins>+#include "LocalizedStrings.h"
</ins><span class="cx"> #include "Logging.h"
</span><span class="cx"> #include "MainFrame.h"
</span><span class="cx"> #include "MemoryCache.h"
</span><span class="lines">@@ -513,11 +515,18 @@
</span><span class="cx"> return nullptr;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(CONTENT_EXTENSIONS)
</span><del>- if (frame() && frame()->mainFrame().page() && frame()->mainFrame().page()->userContentController() && m_documentLoader)
- frame()->mainFrame().page()->userContentController()->processContentExtensionRulesForLoad(request.mutableResourceRequest(), toResourceType(type), *m_documentLoader);
-
- if (request.mutableResourceRequest().isNull())
- return nullptr;
</del><ins>+ if (frame() && frame()->mainFrame().page() && frame()->mainFrame().page()->userContentController() && m_documentLoader) {
+ if (frame()->mainFrame().page()->userContentController()->processContentExtensionRulesForLoad(request.mutableResourceRequest(), toResourceType(type), *m_documentLoader) == ContentExtensions::BlockedStatus::Blocked) {
+ if (type == CachedResource::Type::MainResource) {
+ auto resource = createResource(type, request.mutableResourceRequest(), request.charset(), sessionID());
+ ASSERT(resource);
+ resource->error(CachedResource::Status::LoadError);
+ resource->setResourceError(ResourceError(ContentExtensions::WebKitContentBlockerDomain, 0, request.resourceRequest().url().string(), WEB_UI_STRING("The URL was blocked by a content blocker", "WebKitErrorBlockedByContentBlocker description")));
+ return resource;
+ }
+ return nullptr;
+ }
+ }
</ins><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> auto& memoryCache = MemoryCache::singleton();
</span></span></pre></div>
<a id="trunkSourceWebCorepageUserContentControllercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/UserContentController.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/UserContentController.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/page/UserContentController.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -208,15 +208,15 @@
</span><span class="cx"> m_contentExtensionBackend->removeAllContentExtensions();
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void UserContentController::processContentExtensionRulesForLoad(ResourceRequest& request, ResourceType resourceType, DocumentLoader& initiatingDocumentLoader)
</del><ins>+ContentExtensions::BlockedStatus UserContentController::processContentExtensionRulesForLoad(ResourceRequest& request, ResourceType resourceType, DocumentLoader& initiatingDocumentLoader)
</ins><span class="cx"> {
</span><span class="cx"> if (!m_contentExtensionBackend)
</span><del>- return;
</del><ins>+ return ContentExtensions::BlockedStatus::NotBlocked;
</ins><span class="cx">
</span><span class="cx"> if (!initiatingDocumentLoader.userContentExtensionsEnabled())
</span><del>- return;
</del><ins>+ return ContentExtensions::BlockedStatus::NotBlocked;
</ins><span class="cx">
</span><del>- m_contentExtensionBackend->processContentExtensionRulesForLoad(request, resourceType, initiatingDocumentLoader);
</del><ins>+ return m_contentExtensionBackend->processContentExtensionRulesForLoad(request, resourceType, initiatingDocumentLoader);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> Vector<ContentExtensions::Action> UserContentController::actionsForResourceLoad(const ResourceLoadInfo& resourceLoadInfo, DocumentLoader& initiatingDocumentLoader)
</span></span></pre></div>
<a id="trunkSourceWebCorepageUserContentControllerh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/UserContentController.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/UserContentController.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/page/UserContentController.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -26,6 +26,7 @@
</span><span class="cx"> #ifndef UserContentController_h
</span><span class="cx"> #define UserContentController_h
</span><span class="cx">
</span><ins>+#include "ContentExtensionActions.h"
</ins><span class="cx"> #include "UserScriptTypes.h"
</span><span class="cx"> #include "UserStyleSheetTypes.h"
</span><span class="cx"> #include <wtf/HashSet.h>
</span><span class="lines">@@ -92,7 +93,7 @@
</span><span class="cx"> WEBCORE_EXPORT void removeUserContentExtension(const String& name);
</span><span class="cx"> WEBCORE_EXPORT void removeAllUserContentExtensions();
</span><span class="cx">
</span><del>- void processContentExtensionRulesForLoad(ResourceRequest&, ResourceType, DocumentLoader& initiatingDocumentLoader);
</del><ins>+ ContentExtensions::BlockedStatus processContentExtensionRulesForLoad(ResourceRequest&, ResourceType, DocumentLoader& initiatingDocumentLoader);
</ins><span class="cx"> Vector<ContentExtensions::Action> actionsForResourceLoad(const ResourceLoadInfo&, DocumentLoader& initiatingDocumentLoader);
</span><span class="cx"> #endif
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformeflErrorsEflcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/efl/ErrorsEfl.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/efl/ErrorsEfl.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/platform/efl/ErrorsEfl.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -42,6 +42,11 @@
</span><span class="cx"> return ResourceError(errorDomainPolicy, PolicyErrorCannotUseRestrictedPort, request.url().string(), ASCIILiteral("Not allowed to use restricted network port"));
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError blockedByContentBlockerError(const ResourceRequest& request)
+{
+ return ResourceError(errorDomainPolicy, PolicyErrorBlockedByContentBlocker, request.url().string(), ASCIILiteral("Blocked by content blocker"));
+}
+
</ins><span class="cx"> ResourceError cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return ResourceError(errorDomainPolicy, PolicyErrorCannotShowURL, request.url().string(), ASCIILiteral("URL cannot be shown"));
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformeflErrorsEflh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/efl/ErrorsEfl.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/efl/ErrorsEfl.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/platform/efl/ErrorsEfl.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -56,7 +56,8 @@
</span><span class="cx"> PolicyErrorCannotShowMimeType = 100,
</span><span class="cx"> PolicyErrorCannotShowURL = 101,
</span><span class="cx"> PolicyErrorFrameLoadInterruptedByPolicyChange = 102,
</span><del>- PolicyErrorCannotUseRestrictedPort = 103
</del><ins>+ PolicyErrorCannotUseRestrictedPort = 103,
+ PolicyErrorBlockedByContentBlocker = 104,
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> enum PluginError {
</span><span class="lines">@@ -82,6 +83,7 @@
</span><span class="cx">
</span><span class="cx"> ResourceError cancelledError(const ResourceRequest&);
</span><span class="cx"> ResourceError blockedError(const ResourceRequest&);
</span><ins>+ResourceError blockedByContentBlockerError(const ResourceRequest&);
</ins><span class="cx"> ResourceError cannotShowURLError(const ResourceRequest&);
</span><span class="cx"> ResourceError interruptedForPolicyChangeError(const ResourceRequest&);
</span><span class="cx"> ResourceError cannotShowMIMETypeError(const ResourceResponse&);
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgtkErrorsGtkcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/gtk/ErrorsGtk.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/gtk/ErrorsGtk.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/platform/gtk/ErrorsGtk.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -39,6 +39,11 @@
</span><span class="cx"> request.url().string(), _("Not allowed to use restricted network port"));
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError blockedByContentBlockerError(const ResourceRequest& request)
+{
+ return ResourceError(errorDomainPolicy, PolicyErrorBlockedByContentBlocker, request.url().string(), _("Blocked by content blocker"));
+}
+
</ins><span class="cx"> ResourceError cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return ResourceError(errorDomainPolicy, PolicyErrorCannotShowURL,
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgtkErrorsGtkh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/gtk/ErrorsGtk.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/gtk/ErrorsGtk.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebCore/platform/gtk/ErrorsGtk.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -49,7 +49,8 @@
</span><span class="cx"> PolicyErrorCannotShowMimeType = 100,
</span><span class="cx"> PolicyErrorCannotShowURL = 101,
</span><span class="cx"> PolicyErrorFrameLoadInterruptedByPolicyChange = 102,
</span><del>- PolicyErrorCannotUseRestrictedPort = 103
</del><ins>+ PolicyErrorCannotUseRestrictedPort = 103,
+ PolicyErrorBlockedByContentBlocker = 104,
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> enum PluginError {
</span><span class="lines">@@ -75,6 +76,7 @@
</span><span class="cx">
</span><span class="cx"> ResourceError cancelledError(const ResourceRequest&);
</span><span class="cx"> ResourceError blockedError(const ResourceRequest&);
</span><ins>+ResourceError blockedByContentBlockerError(const ResourceRequest&);
</ins><span class="cx"> ResourceError cannotShowURLError(const ResourceRequest&);
</span><span class="cx"> ResourceError interruptedForPolicyChangeError(const ResourceRequest&);
</span><span class="cx"> ResourceError cannotShowMIMETypeError(const ResourceResponse&);
</span></span></pre></div>
<a id="trunkSourceWebKitmacChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/ChangeLog (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/ChangeLog        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit/mac/ChangeLog        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1,3 +1,19 @@
</span><ins>+2015-10-06 Alex Christensen <achristensen@webkit.org>
+
+ Report error when main resource is blocked by content blocker
+ https://bugs.webkit.org/show_bug.cgi?id=149719
+ rdar://problem/21970595
+
+ Reviewed by Brady Eidson.
+
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::blockedError):
+ (WebFrameLoaderClient::blockedByContentBlockerError):
+ (WebFrameLoaderClient::cannotShowURLError):
+ Add blockedByContentBlockerError so WebFrameLoaderClient is not an abstract class,
+ but it should be unused because content blockers are not enabled on WK1.
+
</ins><span class="cx"> 2015-10-05 Daniel Bates <dabates@apple.com>
</span><span class="cx">
</span><span class="cx"> DumpRenderTree built with public iOS SDK crashes under -[WebPreferences(WebPrivate) _setCurrentNetworkLoaderSessionCookieAcceptPolicy:]
</span></span></pre></div>
<a id="trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -157,6 +157,7 @@
</span><span class="cx">
</span><span class="cx"> virtual WebCore::ResourceError cancelledError(const WebCore::ResourceRequest&) override;
</span><span class="cx"> virtual WebCore::ResourceError blockedError(const WebCore::ResourceRequest&) override;
</span><ins>+ virtual WebCore::ResourceError blockedByContentBlockerError(const WebCore::ResourceRequest&) override;
</ins><span class="cx"> virtual WebCore::ResourceError cannotShowURLError(const WebCore::ResourceRequest&) override;
</span><span class="cx"> virtual WebCore::ResourceError interruptedForPolicyChangeError(const WebCore::ResourceRequest&) override;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClientmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1147,6 +1147,11 @@
</span><span class="cx"> return [NSError _webKitErrorWithDomain:WebKitErrorDomain code:WebKitErrorCannotUseRestrictedPort URL:request.url()];
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError WebFrameLoaderClient::blockedByContentBlockerError(const ResourceRequest& request)
+{
+ RELEASE_ASSERT_NOT_REACHED(); // Content blockers are not enabled in WebKit1.
+}
+
</ins><span class="cx"> ResourceError WebFrameLoaderClient::cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return [NSError _webKitErrorWithDomain:WebKitErrorDomain code:WebKitErrorCannotShowURL URL:request.url()];
</span></span></pre></div>
<a id="trunkSourceWebKitwinChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/ChangeLog (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/ChangeLog        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit/win/ChangeLog        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1,3 +1,18 @@
</span><ins>+2015-10-06 Alex Christensen <achristensen@webkit.org>
+
+ Report error when main resource is blocked by content blocker
+ https://bugs.webkit.org/show_bug.cgi?id=149719
+ rdar://problem/21970595
+
+ Reviewed by Brady Eidson.
+
+ * WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebFrameLoaderClient::blockedError):
+ (WebFrameLoaderClient::blockedByContentBlockerError):
+ (WebFrameLoaderClient::cannotShowURLError):
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ Added stub that should never be used.
+
</ins><span class="cx"> 2015-09-30 Timothy Horton <timothy_horton@apple.com>
</span><span class="cx">
</span><span class="cx"> Compute document marker rects at use time instead of paint time
</span></span></pre></div>
<a id="trunkSourceWebKitwinWebCoreSupportWebFrameLoaderClientcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -858,6 +858,11 @@
</span><span class="cx"> return ResourceError(String(WebKitErrorDomain), WebKitErrorCannotUseRestrictedPort, request.url().string(), WEB_UI_STRING("Not allowed to use restricted network port", "WebKitErrorCannotUseRestrictedPort description"));
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError WebFrameLoaderClient::blockedByContentBlockerError(const ResourceRequest& request)
+{
+ RELEASE_ASSERT_NOT_REACHED(); // Content Blockers are not enabled for WK1.
+}
+
</ins><span class="cx"> ResourceError WebFrameLoaderClient::cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return ResourceError(String(WebKitErrorDomain), WebKitErrorCannotShowURL, request.url().string(), WEB_UI_STRING("The URL can\xE2\x80\x99t be shown", "WebKitErrorCannotShowURL description"));
</span></span></pre></div>
<a id="trunkSourceWebKitwinWebCoreSupportWebFrameLoaderClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit/win/WebCoreSupport/WebFrameLoaderClient.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -141,6 +141,7 @@
</span><span class="cx">
</span><span class="cx"> virtual WebCore::ResourceError cancelledError(const WebCore::ResourceRequest&) override;
</span><span class="cx"> virtual WebCore::ResourceError blockedError(const WebCore::ResourceRequest&) override;
</span><ins>+ virtual WebCore::ResourceError blockedByContentBlockerError(const WebCore::ResourceRequest&) override;
</ins><span class="cx"> virtual WebCore::ResourceError cannotShowURLError(const WebCore::ResourceRequest&) override;
</span><span class="cx"> virtual WebCore::ResourceError interruptedForPolicyChangeError(const WebCore::ResourceRequest&) override;
</span><span class="cx"> virtual WebCore::ResourceError cannotShowMIMETypeError(const WebCore::ResourceResponse&) override;
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/ChangeLog        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1,3 +1,32 @@
</span><ins>+2015-10-06 Alex Christensen <achristensen@webkit.org>
+
+ Report error when main resource is blocked by content blocker
+ https://bugs.webkit.org/show_bug.cgi?id=149719
+ rdar://problem/21970595
+
+ Reviewed by Brady Eidson.
+
+ * Shared/API/c/WKErrorRef.h:
+ * WebProcess/WebCoreSupport/WebErrors.h:
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebKit::WebFrameLoaderClient::blockedError):
+ (WebKit::WebFrameLoaderClient::blockedByContentBlockerError):
+ (WebKit::WebFrameLoaderClient::cannotShowURLError):
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+ * WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp:
+ (WebKit::blockedError):
+ (WebKit::blockedByContentBlockerError):
+ (WebKit::cannotShowURLError):
+ * WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp:
+ (WebKit::blockedError):
+ (WebKit::blockedByContentBlockerError):
+ (WebKit::cannotShowURLError):
+ * WebProcess/WebCoreSupport/mac/WebErrorsMac.mm:
+ (WebKit::blockedError):
+ (WebKit::blockedByContentBlockerError):
+ (WebKit::cannotShowURLError):
+ Make a new error type for loads that were blocked by a content blocker.
+
</ins><span class="cx"> 2015-10-05 Jer Noble <jer.noble@apple.com>
</span><span class="cx">
</span><span class="cx"> [iOS] REGRESSION(r190434): Media continues to play when locking screen
</span></span></pre></div>
<a id="trunkSourceWebKit2SharedAPIcWKErrorRefh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/Shared/API/c/WKErrorRef.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/API/c/WKErrorRef.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/Shared/API/c/WKErrorRef.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -37,6 +37,7 @@
</span><span class="cx"> kWKErrorCodeCannotShowURL = 101,
</span><span class="cx"> kWKErrorCodeFrameLoadInterruptedByPolicyChange = 102,
</span><span class="cx"> kWKErrorCodeCannotUseRestrictedPort = 103,
</span><ins>+ kWKErrorCodeFrameLoadBlockedByContentBlocker = 104,
</ins><span class="cx"> kWKErrorCodeCannotFindPlugIn = 200,
</span><span class="cx"> kWKErrorCodeCannotLoadPlugIn = 201,
</span><span class="cx"> kWKErrorCodeJavaUnavailable = 202,
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebErrorsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebErrors.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebErrors.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebErrors.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -37,6 +37,7 @@
</span><span class="cx">
</span><span class="cx"> WebCore::ResourceError cancelledError(const WebCore::ResourceRequest&);
</span><span class="cx"> WebCore::ResourceError blockedError(const WebCore::ResourceRequest&);
</span><ins>+WebCore::ResourceError blockedByContentBlockerError(const WebCore::ResourceRequest&);
</ins><span class="cx"> WebCore::ResourceError cannotShowURLError(const WebCore::ResourceRequest&);
</span><span class="cx"> WebCore::ResourceError interruptedForPolicyChangeError(const WebCore::ResourceRequest&);
</span><span class="cx"> WebCore::ResourceError cannotShowMIMETypeError(const WebCore::ResourceResponse&);
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClientcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -1103,6 +1103,11 @@
</span><span class="cx"> return WebKit::blockedError(request);
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError WebFrameLoaderClient::blockedByContentBlockerError(const ResourceRequest& request)
+{
+ return WebKit::blockedByContentBlockerError(request);
+}
+
</ins><span class="cx"> ResourceError WebFrameLoaderClient::cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return WebKit::cannotShowURLError(request);
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -141,6 +141,7 @@
</span><span class="cx">
</span><span class="cx"> virtual WebCore::ResourceError cancelledError(const WebCore::ResourceRequest&) override;
</span><span class="cx"> virtual WebCore::ResourceError blockedError(const WebCore::ResourceRequest&) override;
</span><ins>+ virtual WebCore::ResourceError blockedByContentBlockerError(const WebCore::ResourceRequest&) override;
</ins><span class="cx"> virtual WebCore::ResourceError cannotShowURLError(const WebCore::ResourceRequest&) override;
</span><span class="cx"> virtual WebCore::ResourceError interruptedForPolicyChangeError(const WebCore::ResourceRequest&) override;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupporteflWebErrorsEflcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -47,6 +47,11 @@
</span><span class="cx"> return WebCore::blockedError(request);
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError blockedByContentBlockerError(const ResourceRequest& request)
+{
+ return WebCore::blockedByContentBlockerError(request);
+}
+
</ins><span class="cx"> ResourceError cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return WebCore::cannotShowURLError(request);
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportgtkWebErrorsGtkcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -50,6 +50,11 @@
</span><span class="cx"> return WebCore::blockedError(request);
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError blockedByContentBlockerError(const ResourceRequest& request)
+{
+ return WebCore::blockedByContentBlockerError(request);
+}
+
</ins><span class="cx"> ResourceError cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return WebCore::cannotShowURLError(request);
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportmacWebErrorsMacmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm (190610 => 190611)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm        2015-10-06 08:02:00 UTC (rev 190610)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm        2015-10-06 08:18:08 UTC (rev 190611)
</span><span class="lines">@@ -67,6 +67,11 @@
</span><span class="cx"> return ResourceError(API::Error::webKitErrorDomain(), kWKErrorCodeCannotUseRestrictedPort, request.url(), WEB_UI_STRING("Not allowed to use restricted network port", "WebKitErrorCannotUseRestrictedPort description"));
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ResourceError blockedByContentBlockerError(const ResourceRequest& request)
+{
+ return ResourceError(API::Error::webKitErrorDomain(), kWKErrorCodeFrameLoadBlockedByContentBlocker, request.url(), WEB_UI_STRING("The URL was blocked by a content blocker", "WebKitErrorBlockedByContentBlocker description"));
+}
+
</ins><span class="cx"> ResourceError cannotShowURLError(const ResourceRequest& request)
</span><span class="cx"> {
</span><span class="cx"> return ResourceError(API::Error::webKitErrorDomain(), kWKErrorCodeCannotShowURL, request.url(), WEB_UI_STRING("The URL can’t be shown", "WebKitErrorCannotShowURL description"));
</span></span></pre>
</div>
</div>
</body>
</html>