Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(990)

Unified Diff: Source/modules/fetch/Body.cpp

Issue 838003006: Add use counters for Fetch API. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebase Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/frame/UseCounter.h ('k') | Source/modules/fetch/GlobalFetch.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/fetch/Body.cpp
diff --git a/Source/modules/fetch/Body.cpp b/Source/modules/fetch/Body.cpp
index b8c046ef4287af98400040e5378606dc5e2f8309..149f03bcb035dc49e2e5ab7b6b4913564f48632e 100644
--- a/Source/modules/fetch/Body.cpp
+++ b/Source/modules/fetch/Body.cpp
@@ -14,6 +14,7 @@
#include "core/fileapi/Blob.h"
#include "core/fileapi/FileReaderLoader.h"
#include "core/fileapi/FileReaderLoaderClient.h"
+#include "core/frame/UseCounter.h"
#include "core/streams/UnderlyingSource.h"
#include "modules/fetch/BodyStreamBuffer.h"
@@ -237,6 +238,7 @@ ScriptPromise Body::text(ScriptState* scriptState)
ReadableStream* Body::body()
{
+ UseCounter::count(executionContext(), UseCounter::FetchBodyStream);
if (!m_streamAccessed) {
m_streamAccessed = true;
if (m_stream->isPulling()) {
« no previous file with comments | « Source/core/frame/UseCounter.h ('k') | Source/modules/fetch/GlobalFetch.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698