Increased socket flooding detection threshold

This commit is contained in:
Matt 2014-05-07 12:24:29 -06:00
parent 74b6cc0052
commit dc17481db6

View File

@ -206,7 +206,7 @@ var StratumClient = function(options){
} }
socket.on('data', function(d){ socket.on('data', function(d){
dataBuffer += d; dataBuffer += d;
if (Buffer.byteLength(dataBuffer, 'utf8') > 1024){ if (Buffer.byteLength(dataBuffer, 'utf8') > 10240){ //10KB
dataBuffer = ''; dataBuffer = '';
_this.emit('socketFlooded'); _this.emit('socketFlooded');
socket.destroy(); socket.destroy();