diff options
Diffstat (limited to 'src/socket.cpp')
-rw-r--r-- | src/socket.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/socket.cpp b/src/socket.cpp index a1f322b50..4ae2f6768 100644 --- a/src/socket.cpp +++ b/src/socket.cpp @@ -278,7 +278,7 @@ bool InspSocket::FlushWriteBuffer() } else { - outbuffer[0] = outbuffer[0].substr(result + 1,outbuffer[0].length()); + outbuffer[0] = outbuffer[0].substr(result + 1,outbuffer[0].length() - result); } } else if ((result == -1) && (errno != EAGAIN)) @@ -398,5 +398,6 @@ void InspSocket::OnClose() { return; } InspSocket::~InspSocket() { + outbuffer.clear(); this->Close(); } |