Fix segmented reads on local files. r=warren
git-svn-id: svn://10.0.0.236/trunk@69559 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -192,7 +192,7 @@ nsBufferedInputStream::Read(char * buf, PRUint32 count, PRUint32 *result)
|
||||
while (count > 0) {
|
||||
PRUint32 amt = PR_MIN(count, mFillPoint - mCursor);
|
||||
if (amt > 0) {
|
||||
nsCRT::memcpy(buf, mBuffer + mCursor, amt);
|
||||
nsCRT::memcpy(buf + read, mBuffer + mCursor, amt);
|
||||
read += amt;
|
||||
count -= amt;
|
||||
mCursor += amt;
|
||||
|
||||
Reference in New Issue
Block a user