Working on block receive capability.

This commit is contained in:
barant committed 2020-10-20 10:53:06 -07:00
1 parent 58dfd063f3
commit 177bc602af
2 files changed
+15 -7

No files matched your search

+2 -2
View File
@@ -39,7 +39,7 @@ namespace core {
while(lineBufferSize > 0) {
switch(mode) {
case LINE:
int lineLength = strcspn(lineBuffer, "\r\n");
lineLength = strcspn(lineBuffer, "\r\n");
if(lineLength == lineBufferSize)
break;
onLineReceived(std::string(lineBuffer, lineLength));
@@ -66,7 +66,7 @@ namespace core {
}
}
void setMode(Mode mode, int blockSize = 0) {
void TCPSession::setMode(core::Mode mode, int blockSize) {
this->mode = mode;
this->blockSize = blockSize;
}