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

Issue 660396: Fix a CHECK() being hit when the safebrowsing check fires. (Closed)

Created:
10 years, 9 months ago by eroman
Modified:
9 years, 6 months ago
Reviewers:
wtc
CC:
chromium-reviews, jam+cc_chromium.org, brettw+cc_chromium.org, Paul Godavari, darin-cc_chromium.org, ben+cc_chromium.org
Visibility:
Public.

Description

Fix a CHECK() being hit when the safebrowsing check times out (passing in empty URL but expecting the deferred URL). BUG=37195, 33572 TBR=wtc Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=40426

Patch Set 1 #

Patch Set 2 : Add a log message #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -2 lines) Patch
M chrome/browser/renderer_host/safe_browsing_resource_handler.cc View 1 2 chunks +3 lines, -2 lines 2 comments Download

Messages

Total messages: 3 (0 generated)
eroman
10 years, 9 months ago (2010-03-02 20:46:12 UTC) #1
wtc
LGTM. http://codereview.chromium.org/660396/diff/1003/1004 File chrome/browser/renderer_host/safe_browsing_resource_handler.cc (right): http://codereview.chromium.org/660396/diff/1003/1004#newcode150 chrome/browser/renderer_host/safe_browsing_resource_handler.cc:150: CHECK(url == deferred_url_) << "Was expecting: " << ...
10 years, 9 months ago (2010-03-02 21:37:08 UTC) #2
eroman
10 years, 9 months ago (2010-03-02 21:44:19 UTC) #3
http://codereview.chromium.org/660396/diff/1003/1004
File chrome/browser/renderer_host/safe_browsing_resource_handler.cc (right):

http://codereview.chromium.org/660396/diff/1003/1004#newcode150
chrome/browser/renderer_host/safe_browsing_resource_handler.cc:150: CHECK(url ==
deferred_url_) << "Was expecting: " << deferred_url_
On 2010/03/02 21:37:08, wtc wrote:
> If the |url| argument must be equal to the |deferred_url_|
> member, why do we still need the |url| argument?

The redirect bug would be failing in this method, since it had a mismatch
between what the URL was completing for and what it was waiting for. The check
is to guard against those sort of mistakes. Until this code is unit tested, I
think such checks are necessary as a minimum bar for correctness.

Powered by Google App Engine
This is Rietveld 408576698