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

Issue 545093: Refactor host network (Closed)

Created:
10 years, 11 months ago by stoyan
Modified:
9 years, 7 months ago
Reviewers:
amit, ananta
CC:
chromium-reviews_googlegroups.com, amit
Visibility:
Public.

Description

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Patch Set 4 : '' #

Patch Set 5 : '' #

Total comments: 24

Patch Set 6 : '' #

Patch Set 7 : '' #

Patch Set 8 : '' #

Total comments: 38

Patch Set 9 : '' #

Patch Set 10 : '' #

Patch Set 11 : '' #

Patch Set 12 : '' #

Patch Set 13 : '' #

Patch Set 14 : '' #

Total comments: 41

Patch Set 15 : '' #

Patch Set 16 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1489 lines, -1009 lines) Patch
M chrome_frame/chrome_active_document.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -4 lines 0 comments Download
M chrome_frame/chrome_active_document.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +13 lines, -22 lines 0 comments Download
M chrome_frame/chrome_frame.gyp View 11 12 13 14 3 chunks +4 lines, -1 line 0 comments Download
M chrome_frame/chrome_frame_activex.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +5 lines, -0 lines 0 comments Download
M chrome_frame/chrome_frame_activex_base.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +12 lines, -87 lines 0 comments Download
M chrome_frame/chrome_frame_automation.h View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +29 lines, -19 lines 0 comments Download
M chrome_frame/chrome_frame_automation.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +91 lines, -116 lines 0 comments Download
M chrome_frame/chrome_frame_npapi.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +5 lines, -13 lines 0 comments Download
M chrome_frame/chrome_frame_npapi.cc View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +24 lines, -51 lines 0 comments Download
M chrome_frame/chrome_frame_npapi_entrypoints.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +22 lines, -25 lines 0 comments Download
M chrome_frame/http_negotiate.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +41 lines, -3 lines 0 comments Download
M chrome_frame/npapi_url_request.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +42 lines, -24 lines 0 comments Download
M chrome_frame/npapi_url_request.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 8 chunks +162 lines, -11 lines 0 comments Download
M chrome_frame/plugin_url_request.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 6 chunks +77 lines, -60 lines 0 comments Download
M chrome_frame/plugin_url_request.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +8 lines, -43 lines 0 comments Download
M chrome_frame/test/chrome_frame_test_utils.h View 1 chunk +10 lines, -0 lines 0 comments Download
M chrome_frame/test/chrome_frame_unittests.cc View 11 12 13 14 2 chunks +0 lines, -11 lines 0 comments Download
A chrome_frame/test/url_request_test.cc View 1 chunk +152 lines, -0 lines 0 comments Download
M chrome_frame/urlmon_url_request.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +56 lines, -242 lines 0 comments Download
M chrome_frame/urlmon_url_request.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 19 chunks +409 lines, -277 lines 0 comments Download
A chrome_frame/urlmon_url_request_private.h View 11 12 13 14 1 chunk +307 lines, -0 lines 0 comments Download
M chrome_frame/utils.h View 6 7 8 9 10 11 12 13 14 2 chunks +20 lines, -0 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
stoyan
10 years, 11 months ago (2010-01-15 22:09:05 UTC) #1
amit
The refactoring with RequestManager/Delegate is quite clean. The cut between thread safe and unsafe request ...
10 years, 11 months ago (2010-01-19 10:09:40 UTC) #2
stoyan
http://codereview.chromium.org/545093/diff/1008/1013 File chrome_frame/chrome_frame_automation.cc (right): http://codereview.chromium.org/545093/diff/1008/1013#newcode858 chrome_frame/chrome_frame_automation.cc:858: bool ChromeFrameAutomationClient::ProcessNetworkMessage(TabProxy* tab, On 2010/01/19 10:09:40, amit wrote: > ...
10 years, 11 months ago (2010-01-19 20:07:43 UTC) #3
amit
The code overall looks pretty good. I'd like to see if we can eliminate locking ...
10 years, 11 months ago (2010-01-20 07:13:29 UTC) #4
ananta
Looks great overall. Some comments. http://codereview.chromium.org/545093/diff/5055/5063 File chrome_frame/urlmon_url_request.cc (right): http://codereview.chromium.org/545093/diff/5055/5063#newcode224 chrome_frame/urlmon_url_request.cc:224: class UrlmonUrlRequest It would ...
10 years, 11 months ago (2010-01-20 18:27:00 UTC) #5
stoyan
http://codereview.chromium.org/545093/diff/5055/5060 File chrome_frame/chrome_frame_automation.cc (right): http://codereview.chromium.org/545093/diff/5055/5060#newcode887 chrome_frame/chrome_frame_automation.cc:887: if (false == invoke) { On 2010/01/20 07:13:29, amit ...
10 years, 11 months ago (2010-01-21 22:22:48 UTC) #6
stoyan
ping? I removed the lock as well.
10 years, 11 months ago (2010-01-28 22:46:08 UTC) #7
ananta
Almost there :) http://codereview.chromium.org/545093/diff/2083/2102 File chrome_frame/test/chrome_frame_unittests.cc (right): http://codereview.chromium.org/545093/diff/2083/2102#newcode1952 chrome_frame/test/chrome_frame_unittests.cc:1952: class MockUrlDelegate : public PluginUrlRequestDelegate { ...
10 years, 11 months ago (2010-01-28 23:18:02 UTC) #8
amit
Looks much better, nice cleanup. LGTM with a few nits. http://codereview.chromium.org/545093/diff/2083/2095 File chrome_frame/npapi_url_request.cc (right): http://codereview.chromium.org/545093/diff/2083/2095#newcode222 ...
10 years, 11 months ago (2010-01-29 00:23:04 UTC) #9
stoyan
10 years, 10 months ago (2010-01-29 20:39:42 UTC) #10
http://codereview.chromium.org/545093/diff/2083/2095
File chrome_frame/npapi_url_request.cc (right):

http://codereview.chromium.org/545093/diff/2083/2095#newcode222
chrome_frame/npapi_url_request.cc:222: DCHECK(request.get());
On 2010/01/29 00:23:04, amit wrote:
> nit: if (request) to be on the safe side?

Done.

http://codereview.chromium.org/545093/diff/2083/2094
File chrome_frame/plugin_url_request.h (right):

http://codereview.chromium.org/545093/diff/2083/2094#newcode65
chrome_frame/plugin_url_request.h:65: const IPC::AutomationURLRequest&
request_info) {
On 2010/01/29 00:23:04, amit wrote:
> nit: indent

Done.

http://codereview.chromium.org/545093/diff/2083/2102
File chrome_frame/test/chrome_frame_unittests.cc (right):

http://codereview.chromium.org/545093/diff/2083/2102#newcode1952
chrome_frame/test/chrome_frame_unittests.cc:1952: class MockUrlDelegate : public
PluginUrlRequestDelegate {
On 2010/01/28 23:18:02, ananta wrote:
> Nice tests :) Can you move them to a separate file?
> 

Done.

http://codereview.chromium.org/545093/diff/2083/2102#newcode1952
chrome_frame/test/chrome_frame_unittests.cc:1952: class MockUrlDelegate : public
PluginUrlRequestDelegate {
On 2010/01/29 00:23:04, amit wrote:
> On 2010/01/28 23:18:02, ananta wrote:
> > Nice tests :) Can you move them to a separate file?
> > 
> +1
> 

Done.

http://codereview.chromium.org/545093/diff/2083/2102#newcode1981
chrome_frame/test/chrome_frame_unittests.cc:1981: TEST(UrlmonUrlRequestTest,
Simple1) {
On 2010/01/28 23:18:02, ananta wrote:
> A small comment above each test as to what it is testing would be great.
> 

Done.

http://codereview.chromium.org/545093/diff/2083/2102#newcode1987
chrome_frame/test/chrome_frame_unittests.cc:1987: server.SetUp();
On 2010/01/28 23:18:02, ananta wrote:
> Should this block be aligned?

Done.

http://codereview.chromium.org/545093/diff/2083/2102#newcode1999
chrome_frame/test/chrome_frame_unittests.cc:1999: 
On 2010/01/28 23:18:02, ananta wrote:
> Remove additional newlines here and other places below.
> 

Done.

http://codereview.chromium.org/545093/diff/2083/2091
File chrome_frame/urlmon_url_request.cc (right):

http://codereview.chromium.org/545093/diff/2083/2091#newcode450
chrome_frame/urlmon_url_request.cc:450:
status_.set_result(URLRequestStatus::FAILED, net::ERR_INVALID_URL);
On 2010/01/28 23:18:02, ananta wrote:
> ERR_METHOD_NOT_SUPPORTED?

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode657
chrome_frame/urlmon_url_request.cc:657: const wchar_t* url_cstr = url.c_str();
On 2010/01/28 23:18:02, ananta wrote:
> Remove this and just use url.c_str()?

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode659
chrome_frame/urlmon_url_request.cc:659: // Note that there's really no way for
us here to distinguish session cookies
On 2010/01/29 00:23:04, amit wrote:
> nit: 80

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode1016
chrome_frame/urlmon_url_request.cc:1016:
ctx->QueryInterface(moniker_for_url_->bind_ctx.Receive());
On 2010/01/28 23:18:02, ananta wrote:
> DCHECK for success here?
> 

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode1044
chrome_frame/urlmon_url_request.cc:1044: 
On 2010/01/29 00:23:04, amit wrote:
> DCHECK thread affinity in *Worker functions

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode1045
chrome_frame/urlmon_url_request.cc:1045: scoped_ptr<MonikerForUrl>
moniker_for_url(use_moniker);
On 2010/01/29 00:23:04, amit wrote:
> move below the if (stopping_) check?

MonikerForUrl will be leaked.

http://codereview.chromium.org/545093/diff/2083/2091#newcode1132
chrome_frame/urlmon_url_request.cc:1132: // DCHECK_EQ(0,
UrlmonUrlRequest::instance_count_);
On 2010/01/29 00:23:04, amit wrote:
> uncomment?

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode1175
chrome_frame/urlmon_url_request.cc:1175: int request_id, bool erase) {
On 2010/01/28 23:18:02, ananta wrote:
> Can we avoid the Lookup function from providing a facility to erase?. That
could
> live in its own function?

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode1177
chrome_frame/urlmon_url_request.cc:1177: scoped_refptr<UrlmonUrlRequest>
request;
On 2010/01/28 23:18:02, ananta wrote:
> Remove this request variable and just return (*it).second?

Done.

http://codereview.chromium.org/545093/diff/2083/2091#newcode1207
chrome_frame/urlmon_url_request.cc:1207: done.Wait();
On 2010/01/28 23:18:02, ananta wrote:
> Can you clarify why we need to wait here?. It would be great if this can be
> commented in code.
> 

Done. This is a sync call. Caller needs moniker before continuing. I did not
want to introduce another callback in ActiveX object.

http://codereview.chromium.org/545093/diff/2083/2103
File chrome_frame/urlmon_url_request_private.h (right):

http://codereview.chromium.org/545093/diff/2083/2103#newcode272
chrome_frame/urlmon_url_request_private.h:272: 
On 2010/01/28 23:18:02, ananta wrote:
> Remove additional newline.

Done.

http://codereview.chromium.org/545093/diff/2083/2100
File chrome_frame/utils.h (right):

http://codereview.chromium.org/545093/diff/2083/2100#newcode319
chrome_frame/utils.h:319: // Thread that enters STA and have an UI message loop.
On 2010/01/28 23:18:02, ananta wrote:
> has a?

Done.

Powered by Google App Engine
This is Rietveld 408576698