[Libreoffice-commits] core.git: io/source
Stephan Bergmann
sbergman at redhat.com
Fri Nov 21 09:33:10 PST 2014
io/source/TextInputStream/TextInputStream.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 7a0bfcbce147eff61dc9b7d243b571dd34110df8
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Fri Nov 21 18:31:31 2014 +0100
fdo#79941: Properly handle short reads
Change-Id: Ie762ff272410d809382f98a1d446946b566df747
diff --git a/io/source/TextInputStream/TextInputStream.cxx b/io/source/TextInputStream/TextInputStream.cxx
index 1f2db18..ceee33a 100644
--- a/io/source/TextInputStream/TextInputStream.cxx
+++ b/io/source/TextInputStream/TextInputStream.cxx
@@ -294,7 +294,7 @@ sal_Int32 OTextInputStream::implReadNext()
sal_Int32 nBytesToRead = READ_BYTE_COUNT;
sal_Int32 nRead = mxStream->readSomeBytes( mSeqSource, nBytesToRead );
sal_Int32 nTotalRead = nRead;
- if( nRead < nBytesToRead )
+ if( nRead == 0 )
mbReachedEOF = true;
// Try to convert
More information about the Libreoffice-commits
mailing list