Title: [187907] trunk/Source/WebCore
- Revision
- 187907
- Author
- beid...@apple.com
- Date
- 2015-08-04 16:08:55 -0700 (Tue, 04 Aug 2015)
Log Message
Crash when following a Google search link to Twitter with Limit Adult Content enabled.
<rdar://problem/22123707> and https://bugs.webkit.org/show_bug.cgi?id=147651
Reviewed by Sam Weinig.
No new tests (Doesn't occur in a tested config).
For now, we'll skip the application cache for main resource loads if parental controls are enabled.
* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::willSendRequest):
(WebCore::DocumentLoader::startLoadingMainResource):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (187906 => 187907)
--- trunk/Source/WebCore/ChangeLog 2015-08-04 22:58:03 UTC (rev 187906)
+++ trunk/Source/WebCore/ChangeLog 2015-08-04 23:08:55 UTC (rev 187907)
@@ -1,3 +1,18 @@
+2015-08-04 Brady Eidson <beid...@apple.com>
+
+ Crash when following a Google search link to Twitter with Limit Adult Content enabled.
+ <rdar://problem/22123707> and https://bugs.webkit.org/show_bug.cgi?id=147651
+
+ Reviewed by Sam Weinig.
+
+ No new tests (Doesn't occur in a tested config).
+
+ For now, we'll skip the application cache for main resource loads if parental controls are enabled.
+
+ * loader/DocumentLoader.cpp:
+ (WebCore::DocumentLoader::willSendRequest):
+ (WebCore::DocumentLoader::startLoadingMainResource):
+
2015-08-04 Matthew Daiter <mdai...@apple.com>
Added buffer to AVMediaCaptureSource
Modified: trunk/Source/WebCore/loader/DocumentLoader.cpp (187906 => 187907)
--- trunk/Source/WebCore/loader/DocumentLoader.cpp 2015-08-04 22:58:03 UTC (rev 187906)
+++ trunk/Source/WebCore/loader/DocumentLoader.cpp 2015-08-04 23:08:55 UTC (rev 187907)
@@ -77,6 +77,10 @@
#include "ContentFilter.h"
#endif
+#if HAVE(PARENTAL_CONTROLS)
+#include "ParentalControlsContentFilter.h"
+#endif
+
namespace WebCore {
static void cancelAll(const ResourceLoaderMap& loaders)
@@ -549,7 +553,19 @@
if (!redirectResponse.isNull()) {
// We checked application cache for initial URL, now we need to check it for redirected one.
ASSERT(!m_substituteData.isValid());
- m_applicationCacheHost->maybeLoadMainResourceForRedirect(newRequest, m_substituteData);
+
+ bool shouldTryApplicationCache = true;
+
+#if HAVE(PARENTAL_CONTROLS)
+ // There are poor interactions between the ApplicationCache and parental controls (<rdar://problem/22123707>)
+ // so, for now, don't use the AppCache for redirects if parental controls are enabled.
+ if (ParentalControlsContentFilter::enabled())
+ shouldTryApplicationCache = false;
+#endif
+
+ if (shouldTryApplicationCache)
+ m_applicationCacheHost->maybeLoadMainResourceForRedirect(newRequest, m_substituteData);
+
if (m_substituteData.isValid()) {
RELEASE_ASSERT(m_mainResource);
ResourceLoader* loader = m_mainResource->loader();
@@ -1419,8 +1435,18 @@
if (!m_frame || m_request.isNull())
return;
- m_applicationCacheHost->maybeLoadMainResource(m_request, m_substituteData);
+ bool shouldTryApplicationCache = true;
+#if HAVE(PARENTAL_CONTROLS)
+ // There are poor interactions between the ApplicationCache and parental controls (<rdar://problem/22123707>)
+ // so, for now, don't use the AppCache for redirects if parental controls are enabled.
+ if (ParentalControlsContentFilter::enabled())
+ shouldTryApplicationCache = false;
+#endif
+
+ if (shouldTryApplicationCache)
+ m_applicationCacheHost->maybeLoadMainResource(m_request, m_substituteData);
+
if (m_substituteData.isValid()) {
m_identifierForLoadWithoutResourceLoader = m_frame->page()->progress().createUniqueIdentifier();
frameLoader()->notifier().assignIdentifierToInitialRequest(m_identifierForLoadWithoutResourceLoader, this, m_request);
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes