Index: third_party/WebKit/Source/core/loader/appcache/ApplicationCacheHost.cpp |
diff --git a/third_party/WebKit/Source/core/loader/appcache/ApplicationCacheHost.cpp b/third_party/WebKit/Source/core/loader/appcache/ApplicationCacheHost.cpp |
index ad70de0bbead8f9141f15fc29372b275707c65d7..fb2e8a710af31492b54b46eb339cfbb9fefd7830 100644 |
--- a/third_party/WebKit/Source/core/loader/appcache/ApplicationCacheHost.cpp |
+++ b/third_party/WebKit/Source/core/loader/appcache/ApplicationCacheHost.cpp |
@@ -33,8 +33,11 @@ |
#include "bindings/core/v8/ExceptionStatePlaceholder.h" |
#include "core/events/ApplicationCacheErrorEvent.h" |
#include "core/events/ProgressEvent.h" |
+#include "core/frame/Deprecation.h" |
#include "core/frame/LocalFrame.h" |
+#include "core/frame/OriginsUsingFeatures.h" |
#include "core/frame/Settings.h" |
+#include "core/frame/UseCounter.h" |
#include "core/inspector/InspectorApplicationCacheAgent.h" |
#include "core/inspector/InspectorInstrumentation.h" |
#include "core/loader/DocumentLoader.h" |
@@ -115,14 +118,25 @@ void ApplicationCacheHost::selectCacheWithoutManifest() |
void ApplicationCacheHost::selectCacheWithManifest(const KURL& manifestURL) |
{ |
+ DCHECK(m_documentLoader); |
+ |
+ LocalFrame* frame = m_documentLoader->frame(); |
+ Document* document = frame->document(); |
+ if (document->isSecureContext()) { |
+ UseCounter::count(document, UseCounter::ApplicationCacheManifestSelectSecureOrigin); |
+ UseCounter::countCrossOriginIframe(*document, UseCounter::ApplicationCacheManifestSelectSecureOrigin); |
+ } else { |
+ Deprecation::countDeprecation(document, UseCounter::ApplicationCacheManifestSelectInsecureOrigin); |
+ UseCounter::countCrossOriginIframe(*document, UseCounter::ApplicationCacheManifestSelectInsecureOrigin); |
jochen (gone - plz use gerrit)
2016/02/29 15:44:42
This hits ASSERT(Deprecation::deprecationMessage(f
jww
2016/03/01 19:55:02
Yikes, thanks. It appears that I also did this for
|
+ OriginsUsingFeatures::countAnyWorld(*document, OriginsUsingFeatures::Feature::ApplicationCacheManifestSelectInsecureOrigin); |
+ } |
if (m_host && !m_host->selectCacheWithManifest(manifestURL)) { |
// It's a foreign entry, restart the current navigation from the top |
// of the navigation algorithm. The navigation will not result in the |
// same resource being loaded, because "foreign" entries are never picked |
// during navigation. |
// see ApplicationCacheGroup::selectCache() |
- LocalFrame* frame = m_documentLoader->frame(); |
- frame->navigate(*frame->document(), frame->document()->url(), true, UserGestureStatus::None); |
+ frame->navigate(*document, document->url(), true, UserGestureStatus::None); |
} |
} |