diff options
author | Lei Zhang <thestig@chromium.org> | 2015-10-19 17:27:53 -0700 |
---|---|---|
committer | Lei Zhang <thestig@chromium.org> | 2015-10-19 17:27:53 -0700 |
commit | 3884dba163ecfa7b251b1124c4fd9f1c43e578ae (patch) | |
tree | 33774a255c80db831a689bec09e4ddcdde661a75 /fpdfsdk/src/fpdfview.cpp | |
parent | a2deee139f825793462495cc10bbe207ee69e908 (diff) | |
download | pdfium-3884dba163ecfa7b251b1124c4fd9f1c43e578ae.tar.xz |
Merge to XFA: Fix some override warnings in fpdfview.cpp.
TBR=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1410733004 .
(cherry picked from commit 0f2736742f5f9841447a4bd505dcadda22e2f574)
Review URL: https://codereview.chromium.org/1409853003 .
Diffstat (limited to 'fpdfsdk/src/fpdfview.cpp')
-rw-r--r-- | fpdfsdk/src/fpdfview.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/fpdfsdk/src/fpdfview.cpp b/fpdfsdk/src/fpdfview.cpp index 48c8de433f..cfc2f0db04 100644 --- a/fpdfsdk/src/fpdfview.cpp +++ b/fpdfsdk/src/fpdfview.cpp @@ -313,9 +313,9 @@ class CMemFile final : public IFX_FileRead { public: CMemFile(uint8_t* pBuf, FX_FILESIZE size) : m_pBuf(pBuf), m_size(size) {} - virtual void Release() { delete this; } - virtual FX_FILESIZE GetSize() { return m_size; } - virtual FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) { + void Release() override { delete this; } + FX_FILESIZE GetSize() override { return m_size; } + FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override { if (offset < 0) { return FALSE; } @@ -332,9 +332,10 @@ class CMemFile final : public IFX_FileRead { private: ~CMemFile() override {} - uint8_t* m_pBuf; - FX_FILESIZE m_size; + uint8_t* const m_pBuf; + const FX_FILESIZE m_size; }; + DLLEXPORT FPDF_DOCUMENT STDCALL FPDF_LoadMemDocument(const void* data_buf, int size, FPDF_BYTESTRING password) { |