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

Issue 11359143: Make sure Java Bridge cleans up all stub object it creates. (Closed)

Created:
8 years, 1 month ago by acleung
Modified:
8 years ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

Make sure Java Bridge cleans up all stub object it creates. I have been trying to see why the JavaBridgeChannelHost, which is reference counted, sticks around forever. Here is what I found: When talk back is enabled. Each JavaBridgeChannelHost typically have 5 references to it. 3 of them should be cleaned up by this patch. (see comments in the .cc file) BUG=157699 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=170694

Patch Set 1 #

Total comments: 6

Patch Set 2 : address comments #

Total comments: 2

Patch Set 3 : Don't pass by copy to bind() #

Total comments: 4

Patch Set 4 : Fix crash from bad rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -3 lines) Patch
M content/browser/renderer_host/java/java_bridge_dispatcher_host.h View 1 2 chunks +4 lines, -0 lines 0 comments Download
M content/browser/renderer_host/java/java_bridge_dispatcher_host.cc View 1 2 3 3 chunks +21 lines, -3 lines 0 comments Download

Messages

Total messages: 20 (0 generated)
joth
+jam as I think he did most the previous JavaBridge reviews. This change seems to ...
8 years, 1 month ago (2012-11-14 00:51:27 UTC) #1
jam
I'm not familiar with the java version, so hard for me to comment in detail. ...
8 years, 1 month ago (2012-11-14 03:05:56 UTC) #2
darin (slow to review)
https://codereview.chromium.org/11359143/diff/1/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc File content/browser/renderer_host/java/java_bridge_dispatcher_host.cc (right): https://codereview.chromium.org/11359143/diff/1/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc#newcode159 content/browser/renderer_host/java/java_bridge_dispatcher_host.cc:159: std::vector<base::WeakPtr<NPObjectStub> > stubs) { are you sure you want ...
8 years, 1 month ago (2012-11-15 21:08:59 UTC) #3
acleung
https://codereview.chromium.org/11359143/diff/1/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc File content/browser/renderer_host/java/java_bridge_dispatcher_host.cc (right): https://codereview.chromium.org/11359143/diff/1/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc#newcode159 content/browser/renderer_host/java/java_bridge_dispatcher_host.cc:159: std::vector<base::WeakPtr<NPObjectStub> > stubs) { On 2012/11/15 21:08:59, darin wrote: ...
8 years, 1 month ago (2012-11-15 22:39:40 UTC) #4
joth
https://codereview.chromium.org/11359143/diff/5001/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc File content/browser/renderer_host/java/java_bridge_dispatcher_host.cc (right): https://codereview.chromium.org/11359143/diff/5001/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc#newcode54 content/browser/renderer_host/java/java_bridge_dispatcher_host.cc:54: base::Bind(&CleanUpStubs, stubs_)); under the covers, Bind copy-constructs a copy ...
8 years, 1 month ago (2012-11-15 23:29:07 UTC) #5
acleung
https://codereview.chromium.org/11359143/diff/5001/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc File content/browser/renderer_host/java/java_bridge_dispatcher_host.cc (right): https://codereview.chromium.org/11359143/diff/5001/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc#newcode54 content/browser/renderer_host/java/java_bridge_dispatcher_host.cc:54: base::Bind(&CleanUpStubs, stubs_)); On 2012/11/15 23:29:07, joth wrote: > under ...
8 years, 1 month ago (2012-11-16 02:07:18 UTC) #6
acleung
On 2012/11/16 02:07:18, acleung wrote: > https://codereview.chromium.org/11359143/diff/5001/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc > File content/browser/renderer_host/java/java_bridge_dispatcher_host.cc (right): > > https://codereview.chromium.org/11359143/diff/5001/content/browser/renderer_host/java/java_bridge_dispatcher_host.cc#newcode54 > ...
8 years, 1 month ago (2012-11-18 09:26:13 UTC) #7
joth
adding steveblock as he's back online now and may still have some memory of this. ...
8 years ago (2012-11-27 00:16:23 UTC) #8
Steve Block
Perhaps I'm imagining this, but I thought there was logic in the channel whereby if ...
8 years ago (2012-11-27 05:04:32 UTC) #9
acleung
It doesn't seem to be that way. Multiple renderer share the same channel and they ...
8 years ago (2012-11-27 07:48:33 UTC) #10
Steve Block
LGTM Thanks for double-checking
8 years ago (2012-11-28 23:08:05 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/acleung@google.com/11359143/10001
8 years ago (2012-11-29 00:45:46 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/acleung@google.com/11359143/10001
8 years ago (2012-11-29 19:07:08 UTC) #13
commit-bot: I haz the power
The commit queue went berserk retrying too often for a seemingly flaky test. Builder is ...
8 years ago (2012-11-29 23:46:44 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/acleung@google.com/11359143/10001
8 years ago (2012-11-30 18:53:25 UTC) #15
commit-bot: I haz the power
The commit queue went berserk retrying too often for a seemingly flaky test. Builder is ...
8 years ago (2012-11-30 22:14:55 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/acleung@google.com/11359143/10001
8 years ago (2012-11-30 23:37:26 UTC) #17
commit-bot: I haz the power
Commit queue patch verification failed without an error message. Something went wrong, probably a crash, ...
8 years ago (2012-12-01 03:51:58 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/acleung@google.com/11359143/7010
8 years ago (2012-12-02 23:12:02 UTC) #19
commit-bot: I haz the power
8 years ago (2012-12-03 01:10:39 UTC) #20
Message was sent while issue was closed.
Change committed as 170694

Powered by Google App Engine
This is Rietveld 408576698