diff options
author | Lei Zhang <thestig@chromium.org> | 2015-11-10 10:23:29 -0800 |
---|---|---|
committer | Lei Zhang <thestig@chromium.org> | 2015-11-10 10:23:29 -0800 |
commit | e6e16954f0cdc324849fca9da883be8f131b3834 (patch) | |
tree | c1f29469c1cb4ff3811f9d9f9845d2fc2d7a2702 /core/src/fpdfapi/fpdf_page | |
parent | b27902b8995bb3e003daed6b0811ed746763c68d (diff) | |
download | pdfium-e6e16954f0cdc324849fca9da883be8f131b3834.tar.xz |
Cleanup CPDF_Stream:
- Remove CPDF_Stream::Create() and checks that it might fail.
- Remove m_pCryptoHandler that's always a nullptr.
- Remove m_FileOffset that's always 0.
- Rename file version of InitStream() to InitStreamFromFile().
- Use IsMemoryBased() in more places.
R=dsinclair@chromium.org
Review URL: https://codereview.chromium.org/1415163009 .
Diffstat (limited to 'core/src/fpdfapi/fpdf_page')
-rw-r--r-- | core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp index 4b95da8761..a1aa686248 100644 --- a/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp +++ b/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp @@ -444,8 +444,9 @@ CPDF_Stream* CPDF_StreamParser::ReadInlineStream(CPDF_Document* pDoc, } } pDict->SetAtInteger(FX_BSTRC("Length"), (int)dwStreamSize); - return CPDF_Stream::Create(pData, dwStreamSize, pDict); + return new CPDF_Stream(pData, dwStreamSize, pDict); } + #define MAX_WORD_BUFFER 256 #define MAX_STRING_LENGTH 32767 #define FXDWORD_TRUE FXDWORD_FROM_LSBFIRST(0x65757274) |