Merge branch 'master' into fix-165
This commit is contained in:
commit
7469dbac01
2 changed files with 6 additions and 6 deletions
|
@ -464,7 +464,7 @@ or specifying everything UDP
|
|||
|
||||
| method | definition |
|
||||
|-----------|------------|
|
||||
|start| start serving need top call ` serve ` or ` serveNet ` first to set up the server |
|
||||
|start| start serving need to call ` serve ` or ` serveNet ` first to set up the server |
|
||||
|stop| close the server and stop serving |
|
||||
|
||||
----
|
||||
|
|
|
@ -161,18 +161,18 @@ function gotData(socket,data,UDPSocket){
|
|||
return;
|
||||
}
|
||||
|
||||
if(!this.ipcBuffer){
|
||||
this.ipcBuffer='';
|
||||
if(!sock.ipcBuffer){
|
||||
sock.ipcBuffer='';
|
||||
}
|
||||
|
||||
data=(this.ipcBuffer+=data);
|
||||
data=(sock.ipcBuffer+=data);
|
||||
|
||||
if(data.slice(-1)!=eventParser.delimiter || data.indexOf(eventParser.delimiter) == -1){
|
||||
this.log('Messages are large, You may want to consider smaller messages.');
|
||||
return;
|
||||
}
|
||||
|
||||
this.ipcBuffer='';
|
||||
sock.ipcBuffer='';
|
||||
|
||||
data=eventParser.parse(data);
|
||||
|
||||
|
|
Loading…
Reference in a new issue