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

Unified Diff: mojo/public/js/connector.js

Issue 2044183004: Debugging for https://crbug.com/601435. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 | « mojo/edk/js/handle.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/js/connector.js
diff --git a/mojo/public/js/connector.js b/mojo/public/js/connector.js
index 674f36b3210d3fced0abd04c1163fcfac49933b9..9b9061943943950c3dc96480c4e60d1723aa27b2 100644
--- a/mojo/public/js/connector.js
+++ b/mojo/public/js/connector.js
@@ -9,6 +9,9 @@ define("mojo/public/js/connector", [
"mojo/public/js/support",
], function(buffer, codec, core, support) {
+ // Putting the handles somewhere causes them to not get lost.
+ var allHandles = [];
+
function Connector(handle) {
if (!core.isHandle(handle))
throw new Error("Connector: not a handle " + handle);
@@ -44,6 +47,7 @@ define("mojo/public/js/connector", [
if (this.dropWrites_)
return true;
+ allHandles = allHandles.concat(message.handles);
var result = core.writeMessage(this.handle_,
new Uint8Array(message.buffer.arrayBuffer),
message.handles,
« no previous file with comments | « mojo/edk/js/handle.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698