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

Unified Diff: third_party/WebKit/Source/core/fetch/Resource.cpp

Issue 1829403002: Clean up font loading (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Resource_status
Patch Set: Created 4 years, 8 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
Index: third_party/WebKit/Source/core/fetch/Resource.cpp
diff --git a/third_party/WebKit/Source/core/fetch/Resource.cpp b/third_party/WebKit/Source/core/fetch/Resource.cpp
index 7071893e39e0896439d46e8298a240c8d0a6b1a9..6461a9ead08682b3a6f47881c14db13ce1217ac1 100644
--- a/third_party/WebKit/Source/core/fetch/Resource.cpp
+++ b/third_party/WebKit/Source/core/fetch/Resource.cpp
@@ -257,6 +257,7 @@ DEFINE_TRACE(Resource)
void Resource::load(ResourceFetcher* fetcher)
{
RELEASE_ASSERT(!m_loader);
+ ASSERT(stillNeedsLoad());
Nate Chapin 2016/04/07 23:46:16 The changes to ImageResource were to facilitate th
m_status = Pending;
ResourceRequest& request(m_revalidatingRequest.isNull() ? m_resourceRequest : m_revalidatingRequest);
@@ -457,6 +458,12 @@ const ResourceRequest& Resource::lastResourceRequest() const
return m_redirectChain.last().m_request;
}
+void Resource::setRevalidatingRequest(const ResourceRequest& request)
+{
+ m_revalidatingRequest = request;
+ m_status = NotStarted;
Nate Chapin 2016/04/07 23:46:16 Also to enable the ASSERT in Resource::load
+}
+
void Resource::willFollowRedirect(ResourceRequest& newRequest, const ResourceResponse& redirectResponse)
{
newRequest.setAllowStoredCredentials(m_options.allowCredentials == AllowStoredCredentials);

Powered by Google App Engine
This is Rietveld 408576698