summaryrefslogtreecommitdiff
path: root/core/fpdfapi/font/fpdf_font.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/font/fpdf_font.cpp')
-rw-r--r--core/fpdfapi/font/fpdf_font.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/core/fpdfapi/font/fpdf_font.cpp b/core/fpdfapi/font/fpdf_font.cpp
index c827ea5793..b681edf70b 100644
--- a/core/fpdfapi/font/fpdf_font.cpp
+++ b/core/fpdfapi/font/fpdf_font.cpp
@@ -47,11 +47,8 @@ CFX_StockFontArray::CFX_StockFontArray() {}
CFX_StockFontArray::~CFX_StockFontArray() {
for (size_t i = 0; i < FX_ArraySize(m_StockFonts); ++i) {
- if (!m_StockFonts[i])
- continue;
- CPDF_Dictionary* pFontDict = m_StockFonts[i]->GetFontDict();
- if (pFontDict)
- pFontDict->Release();
+ if (m_StockFonts[i])
+ delete m_StockFonts[i]->GetFontDict();
}
}