Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1392)

Unified Diff: core/fxcrt/fx_xml_parser.cpp

Issue 2430743003: in the attempt to fix 627393, changed IFX_FileRead's readBlock to return the length it reads
Patch Set: remove .tmp files Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: core/fxcrt/fx_xml_parser.cpp
diff --git a/core/fxcrt/fx_xml_parser.cpp b/core/fxcrt/fx_xml_parser.cpp
index 9412cdde04192ee4a3611c1bf4b0aaa8930dd7a8..0b5e8638d5dd8c1b5ee5f4070b91ba2cb9015d65 100644
--- a/core/fxcrt/fx_xml_parser.cpp
+++ b/core/fxcrt/fx_xml_parser.cpp
@@ -96,7 +96,8 @@ FX_BOOL CXML_DataStmAcc::ReadNextBlock(FX_BOOL bRestart) {
if (!m_pBuffer) {
m_pBuffer = FX_Alloc(uint8_t, m_dwSize);
}
- return m_pFileRead->ReadBlock(m_pBuffer, m_nStart, m_dwSize);
+ return m_pFileRead->ReadBlock(m_pBuffer, m_nStart, m_dwSize) == m_dwSize ||
+ m_pFileRead->IsEOF();
}
const uint8_t* CXML_DataStmAcc::GetBlockBuffer() {

Powered by Google App Engine
This is Rietveld 408576698