Skip to content

Commit

Permalink
fix timing issue
Browse files Browse the repository at this point in the history
  • Loading branch information
izuzak committed Dec 8, 2012
1 parent 847fe92 commit eca09ff
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pmrpc.js
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,11 @@ pmrpc = self.pmrpc = function() {
"retries" : 0,
"destinationDomain" : callObj.destinationDomain});
callQueue[callId] = callObj;
self.setTimeout(function() { waitAndSendRequest(callId); }, callObj.timeout / callObj.retries);
self.setTimeout(function() {
if (callQueue[callId] && callQueue[callId].status === "pinging") {
waitAndSendRequest(callId);
}
}, callObj.timeout / callObj.retries);
}
}

Expand Down

0 comments on commit eca09ff

Please sign in to comment.