diff options
author | thestig <thestig@chromium.org> | 2016-04-28 17:29:19 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-04-28 17:29:19 -0700 |
commit | 495bda110a6ea8e7a6fc313ec0232a9ca6e3cfdc (patch) | |
tree | 42abda300274f81009bdb9866e0f7e3f81164726 /xfa/fxfa/app/xfa_ffwidget.cpp | |
parent | a31098417852bdf13e693a6e0913e0706cf94098 (diff) | |
download | pdfium-495bda110a6ea8e7a6fc313ec0232a9ca6e3cfdc.tar.xz |
Do not check pointers before deleting them.
XFA edition.
Review-Url: https://codereview.chromium.org/1925363002
Diffstat (limited to 'xfa/fxfa/app/xfa_ffwidget.cpp')
-rw-r--r-- | xfa/fxfa/app/xfa_ffwidget.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/xfa/fxfa/app/xfa_ffwidget.cpp b/xfa/fxfa/app/xfa_ffwidget.cpp index 34b29c79d2..c1af34c030 100644 --- a/xfa/fxfa/app/xfa_ffwidget.cpp +++ b/xfa/fxfa/app/xfa_ffwidget.cpp @@ -526,17 +526,14 @@ CXFA_ImageRenderer::CXFA_ImageRenderer() { m_Result = TRUE; m_bPrint = FALSE; } + CXFA_ImageRenderer::~CXFA_ImageRenderer() { - if (m_pCloneConvert) { - delete m_pCloneConvert; - } - if (m_pTransformer) { - delete m_pTransformer; - } - if (m_DeviceHandle) { + delete m_pCloneConvert; + delete m_pTransformer; + if (m_DeviceHandle) m_pDevice->CancelDIBits(m_DeviceHandle); - } } + FX_BOOL CXFA_ImageRenderer::Start(CFX_RenderDevice* pDevice, CFX_DIBSource* pDIBSource, FX_ARGB bitmap_argb, |