summaryrefslogtreecommitdiffstats
path: root/dom/messagechannel/tests/sharedWorker2_messageChannel.js
blob: 8cc98aa209b82f8162ab0dfe4b773b33e4d7a282 (plain)
1
2
3
4
5
6
7
var mc = new MessageChannel();
var i = 0;

onconnect = function(evt) {
  dump("CONNECTING: "+ i +"\n");
  evt.ports[0].postMessage(42, [mc['port' + ++i]]);
}