summaryrefslogtreecommitdiffstats
path: root/dom/workers/test/bug1104064_worker.js
blob: 5e627c86f5bedb2770bace8bd8a74844eed4eed5 (plain)
1
2
3
4
5
6
7
8
9
10
onmessage = function() {
  var counter = 0;
  var id = setInterval(function() {
    ++counter;
    if (counter == 2) {
      clearInterval(id);
      postMessage('done');
    }
  }, 0);
}