From cfac954abcab7caf47d3fa3d641c553cba998271 Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Fri, 19 Jun 2015 14:51:10 -0700 Subject: Cleanup: Do not check pointers before deleting them. R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1192743004. --- core/src/fxge/ge/fx_ge_font.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'core/src/fxge/ge/fx_ge_font.cpp') diff --git a/core/src/fxge/ge/fx_ge_font.cpp b/core/src/fxge/ge/fx_ge_font.cpp index 8e4e5ac2e3..f88cbaacde 100644 --- a/core/src/fxge/ge/fx_ge_font.cpp +++ b/core/src/fxge/ge/fx_ge_font.cpp @@ -28,10 +28,8 @@ CFX_Font::CFX_Font() } CFX_Font::~CFX_Font() { - if (m_pSubstFont) { - delete m_pSubstFont; - m_pSubstFont = NULL; - } + delete m_pSubstFont; + m_pSubstFont = NULL; if (m_pFontDataAllocation) { FX_Free(m_pFontDataAllocation); m_pFontDataAllocation = NULL; -- cgit v1.2.3