Setting WebSocket buffer to empty once nonce is received (intended to include in previous commit)

This commit is contained in:
mlinnell
2011-02-23 19:01:35 +00:00
parent d2ecaff462
commit 2ee09436ce

View File

@@ -108,6 +108,7 @@ WebSocket.prototype._onConnect = function(req, socket){
self.waitingForNonce = false;
// Stuff the nonce into the location where it's expected to be
self.upgradeHead = self.buffer.substr(0,8);
self.buffer = '';
if (self._proveReception(self._headers)) { self._payload(); }
return;
}