From d314c3bbb03663aea453fd5b5cc0275d93a70ef9 Mon Sep 17 00:00:00 2001 From: Guillermo Rodriguez Garcia Date: Thu, 9 Dec 1999 13:41:52 +0000 Subject: [PATCH] Fixed small bug related to m_lastcount in wxInputStream::Read git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4886 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/stream.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/common/stream.cpp b/src/common/stream.cpp index 5c508e98a2..ebe0c5aa11 100644 --- a/src/common/stream.cpp +++ b/src/common/stream.cpp @@ -585,11 +585,10 @@ wxInputStream& wxInputStream::Read(void *buffer, size_t size) m_lasterror = wxStream_NOERROR; return *this; } - size -= retsize; - buf += retsize; + size -= retsize; + buf += retsize; - // GRG: shouldn't we also add retsize to m_lastcount here? - m_lastcount = OnSysRead(buf, size); + m_lastcount = OnSysRead(buf, size) + retsize; return *this; } -- 2.45.2