diff options
author | fcolin | 2007-02-01 12:53:52 +0000 |
---|---|---|
committer | fcolin | 2007-02-01 12:53:52 +0000 |
commit | 5ccd107ce6f5bc2dff320ba0e540baffaf1a42ec (patch) | |
tree | b1c176e133ccd799b0a551b3a225f36a8a82481c /Bus/Ivy/BufferedSocket.cxx | |
parent | 6b518c7b277f2db1f051449408796c85229253c4 (diff) | |
download | ivy-cplusplus-5ccd107ce6f5bc2dff320ba0e540baffaf1a42ec.zip ivy-cplusplus-5ccd107ce6f5bc2dff320ba0e540baffaf1a42ec.tar.gz ivy-cplusplus-5ccd107ce6f5bc2dff320ba0e540baffaf1a42ec.tar.bz2 ivy-cplusplus-5ccd107ce6f5bc2dff320ba0e540baffaf1a42ec.tar.xz |
Utilisateur : Fcolin Date : 17/11/05 Heure : 15:08 Archivé dans $/Bus/Ivy Commentaire: nice Bug in nextArg not reentrant routine due to static variable (vss 17)
Diffstat (limited to 'Bus/Ivy/BufferedSocket.cxx')
-rw-r--r-- | Bus/Ivy/BufferedSocket.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Bus/Ivy/BufferedSocket.cxx b/Bus/Ivy/BufferedSocket.cxx index 11eecf5..7df2bce 100644 --- a/Bus/Ivy/BufferedSocket.cxx +++ b/Bus/Ivy/BufferedSocket.cxx @@ -55,6 +55,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) nb_to_read = buffer_size - (current_ptr - buffer );
}
nb = ReceiveFrom( current_ptr, nb_to_read, &addr, &len, 0/*MSG_PARTIAL*/ );
+ ASSERT ( memchr( current_ptr, 0, nb) == NULL );
if ( nb == SOCKET_ERROR )
{
int err = this->GetLastError();
@@ -70,7 +71,6 @@ void CBufferedSocket::OnReceive(int nErrorCode) }
current_ptr += nb;
- //ASSERT( current_ptr < (buffer + buffer_size) );
ptr = buffer;
while ((ptr_sep = (char*)memchr (ptr, separator, current_ptr - ptr )))
{
@@ -78,6 +78,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) //TRACE("message %s\n", ptr );
OnReceive( ptr );
ptr = ++ptr_sep;
+ //ASSERT( ptr < (buffer + buffer_size) );
}
if (ptr < current_ptr )
{ /* recopie ligne incomplete au debut du buffer */
|