summaryrefslogtreecommitdiff
path: root/core/src/fpdfapi
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/fpdfapi')
-rw-r--r--core/src/fpdfapi/fpdf_font/fpdf_font.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/core/src/fpdfapi/fpdf_font/fpdf_font.cpp b/core/src/fpdfapi/fpdf_font/fpdf_font.cpp
index 91d4010b80..9ee9621849 100644
--- a/core/src/fpdfapi/fpdf_font/fpdf_font.cpp
+++ b/core/src/fpdfapi/fpdf_font/fpdf_font.cpp
@@ -128,14 +128,12 @@ FX_BOOL CPDF_Font::Initialize()
}
CPDF_Font::~CPDF_Font()
{
- if (m_pCharMap) {
- FX_Free(m_pCharMap);
- m_pCharMap = NULL;
- }
- if (m_pToUnicodeMap) {
- delete m_pToUnicodeMap;
- m_pToUnicodeMap = NULL;
- }
+ delete m_pCharMap;
+ m_pCharMap = NULL;
+
+ delete m_pToUnicodeMap;
+ m_pToUnicodeMap = NULL;
+
if (m_pFontFile) {
m_pDocument->GetPageData()->ReleaseFontFileStreamAcc((CPDF_Stream*)m_pFontFile->GetStream());
}