Index: third_party/WebKit/Source/core/html/ImageDocument.cpp |
diff --git a/third_party/WebKit/Source/core/html/ImageDocument.cpp b/third_party/WebKit/Source/core/html/ImageDocument.cpp |
index 0de08f1ced5b41b7d40d39d7857734ecbb456a4b..37b578bb13bb98e7122e65274a05ecb322e053d0 100644 |
--- a/third_party/WebKit/Source/core/html/ImageDocument.cpp |
+++ b/third_party/WebKit/Source/core/html/ImageDocument.cpp |
@@ -104,7 +104,6 @@ private: |
ImageDocumentParser(ImageDocument* document) |
: RawDataDocumentParser(document) |
{ |
- UseCounter::count(document, UseCounter::ImageDocument); |
} |
void appendBytes(const char*, size_t) override; |
@@ -194,6 +193,9 @@ ImageDocument::ImageDocument(const DocumentInit& initializer) |
{ |
setCompatibilityMode(QuirksMode); |
lockCompatibilityMode(); |
+ UseCounter::count(*this, UseCounter::ImageDocument); |
+ if (ownerElement()) |
+ UseCounter::count(*this, UseCounter::ImageDocumentInFrame); |
} |
DocumentParser* ImageDocument::createParser() |