[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Serious Bug in TCPStream & solution.
From: |
Andrey Kulikov |
Subject: |
Serious Bug in TCPStream & solution. |
Date: |
Fri, 16 Jul 2004 19:32:44 +0400 |
Hi All.
I have found bug in ost::TCPStream. (version 1.2.3, current CVS
version is not available for me).
I'm using TCPStream for geting web-pages from web server.
This bug produce uncompleted page retrieval, or application crash.
The error is in error-handling while end of data detected.
Attached example demonstated this error.
Test 1 showing incomplete text receiving. (ending </html> never
appears)
Test 2 showing application crach due to exception.
========= socket.cpp ==================
L1819 if(rlen < 1)
{
// clear(ios::failbit | rdstate());
if(rlen < 0)
error(errNotConnected,"Connection error",socket_errno);
else
{
L1826 error(errInput,"Could not read from
socket",socket_errno);
clear(ios::failbit | rdstate());
}
return EOF;
L1830 }
=======================================
For propely working line 1826 shuld be commented (or removed).
--
Best regards,
Andrey mailto:address@hidden
TcpStreamBugTest.cpp
Description: Text document
stdafx.h
Description: Text document
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Serious Bug in TCPStream & solution.,
Andrey Kulikov <=