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

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

Issue 1634943003: Replace if-block on !redirectResponse.isNull() with ASSERT in RawResource::willFollowRedirect() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/fetch/RawResource.cpp
diff --git a/third_party/WebKit/Source/core/fetch/RawResource.cpp b/third_party/WebKit/Source/core/fetch/RawResource.cpp
index 381f9acc30ccc9c2a5a18d1f3be9649cf39bab05..9bc2cd441c69838cb6e650b6cabfdceb2e3c968a 100644
--- a/third_party/WebKit/Source/core/fetch/RawResource.cpp
+++ b/third_party/WebKit/Source/core/fetch/RawResource.cpp
@@ -132,11 +132,10 @@ void RawResource::didAddClient(ResourceClient* c)
void RawResource::willFollowRedirect(ResourceRequest& newRequest, const ResourceResponse& redirectResponse)
{
ResourcePtr<RawResource> protect(this);
- if (!redirectResponse.isNull()) {
- ResourceClientWalker<RawResourceClient> w(m_clients);
- while (RawResourceClient* c = w.next())
- c->redirectReceived(this, newRequest, redirectResponse);
- }
+ ASSERT(!redirectResponse.isNull());
+ ResourceClientWalker<RawResourceClient> w(m_clients);
+ while (RawResourceClient* c = w.next())
+ c->redirectReceived(this, newRequest, redirectResponse);
Resource::willFollowRedirect(newRequest, redirectResponse);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698