Skip to content

Commit

Permalink
Make channel private after small delay
Browse files Browse the repository at this point in the history
(but only if our wrapped asyncOpen()/open() wasn't called)
(workaround for #150)
  • Loading branch information
Infocatcher committed May 27, 2014
1 parent d6b985d commit 55e46e2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions protocol.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ var privateProtocol = {
return channel.open.apply(this, arguments);
}
};
Services.tm.mainThread.dispatch(function() {
_log("[protocol] fallback delay => ensurePrivate()");
ensurePrivate();
}, Components.interfaces.nsIThread.DISPATCH_NORMAL);
return channelWrapper;
},

Expand Down

0 comments on commit 55e46e2

Please sign in to comment.