diff options
author | fcolin | 2009-10-15 10:26:27 +0000 |
---|---|---|
committer | fcolin | 2009-10-15 10:26:27 +0000 |
commit | 473bf59297a9c8010fb35f505c872024ae3d259d (patch) | |
tree | ba296d860b9ecda9101b76f1eea4407daa997a38 /Ivy/BufferedSocket.cxx | |
parent | 3bd1423d9bd7374c2d39f9817e3a1caa836f86e6 (diff) | |
download | ivy-cplusplus-473bf59297a9c8010fb35f505c872024ae3d259d.zip ivy-cplusplus-473bf59297a9c8010fb35f505c872024ae3d259d.tar.gz ivy-cplusplus-473bf59297a9c8010fb35f505c872024ae3d259d.tar.bz2 ivy-cplusplus-473bf59297a9c8010fb35f505c872024ae3d259d.tar.xz |
correction bug threaded IvyApplication
correction checkconnected self
Diffstat (limited to 'Ivy/BufferedSocket.cxx')
-rw-r--r-- | Ivy/BufferedSocket.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index fcf90c6..b91386f 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -24,6 +24,7 @@ CBufferedSocket::CBufferedSocket() CBufferedSocket::~CBufferedSocket()
{
free( buffer );
+ DeleteCriticalSection( &m_CritSection );
}
void CBufferedSocket::Accept(CBufferedSocket& rConnectedSocket, SOCKADDR* lpSockAddr , int* lpSockAddrLen )
{
@@ -74,7 +75,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) current_ptr += nb;
ptr = buffer;
- while ((ptr_sep = (char*)memchr (ptr, separator, current_ptr - ptr )))
+ while ((ptr_sep = (char*)memchr (ptr, separator, current_ptr - ptr )) && m_hSocket != INVALID_SOCKET)
{
*ptr_sep = '\0';
//TRACE("message %s\n", ptr );
|