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

Issue 39104: Implementation of ResourceDispatcher::OnDownloadProgress (Closed)

Created:
11 years, 9 months ago by Alpha Left Google
Modified:
9 years, 6 months ago
CC:
chromium-reviews_googlegroups.com, scherkus (not reviewing), ralphl, fbarchard
Visibility:
Public.

Description

Implementation of ResourceDispatcher::OnDownloadProgress Implemented ResourceDispatcher::OnDownloadProgress to handle ViewMsg_DownloadProgress IPC message, implementation is a clone of ResourceDispatcher::OnUploadProgress because they have identical behavior.

Patch Set 1 #

Total comments: 8
Unified diffs Side-by-side diffs Delta from patch set Stats (+18 lines, -3 lines) Patch
M chrome/common/resource_dispatcher.cc View 1 chunk +18 lines, -3 lines 8 comments Download

Messages

Total messages: 3 (0 generated)
Alpha Left Google
Implementation of ResourceDispatcher::OnDownloadProgress copying ResourceDispatcher::OnUploadProgress, this patch is depending on my other patch that adds ...
11 years, 9 months ago (2009-03-04 02:18:26 UTC) #1
Erik does not do reviews
LGTM http://codereview.chromium.org/39104/diff/1/2 File chrome/common/resource_dispatcher.cc (right): http://codereview.chromium.org/39104/diff/1/2#newcode285 Line 285: DLOG(WARNING) << "Got download progress for a ...
11 years, 9 months ago (2009-03-04 17:55:44 UTC) #2
Alpha Left Google
11 years, 9 months ago (2009-03-05 00:32:06 UTC) #3
http://codereview.chromium.org/39104/diff/1/2
File chrome/common/resource_dispatcher.cc (right):

http://codereview.chromium.org/39104/diff/1/2#newcode285
Line 285: DLOG(WARNING) << "Got download progress for a nonexistant or "
On 2009/03/04 17:55:44, Erik Kay wrote:
> should this be a DCHECK?

I guess browser process can accidentally send resource messages to renderer with
invalid request_id sometimes, it would be better log it than crash the whole
renderer.

http://codereview.chromium.org/39104/diff/1/2#newcode292
Line 292: RESOURCE_LOG("Dispatching download progress for " <<
On 2009/03/04 17:55:44, Erik Kay wrote:
> this log macro looks different than our normal style.  I'd expect it to be
> RESOURCE_LOG("msg") << extra; rather than RESOURCE_LOG("msg" << extra);  Is
this
> correct?

It looks strange to me too, but seems the whole file is using this style, I
would prefer making it coherent.

http://codereview.chromium.org/39104/diff/1/2#newcode294
Line 294: request_info.peer->OnDownloadProgress(position, size);
On 2009/03/04 17:55:44, Erik Kay wrote:
> is request_info.peer guaranteed to be non-null?  DCHECK?

This assumption is made throughout this file too.

http://codereview.chromium.org/39104/diff/1/2#newcode298
Line 298: if (sender)
On 2009/03/04 17:55:44, Erik Kay wrote:
> Since the contents of the if wrap to multiple lines, use {} to make it more
> clear.

Done.

Powered by Google App Engine
This is Rietveld 408576698