Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2270)

Unified Diff: xfa/fxgraphics/cagg_graphics.cpp

Issue 1925363002: Do not check pointers before deleting them. (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: rebase Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « xfa/fxfa/parser/xfa_script_resolveprocessor.cpp ('k') | xfa/fxgraphics/cfx_path_generator.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fxgraphics/cagg_graphics.cpp
diff --git a/xfa/fxgraphics/cagg_graphics.cpp b/xfa/fxgraphics/cagg_graphics.cpp
index 4c9e41fea3c6c7eec3eb66b5d4119f3eb9a6c0df..a4211810c40371edf0ce6079426e21f75944b9de 100644
--- a/xfa/fxgraphics/cagg_graphics.cpp
+++ b/xfa/fxgraphics/cagg_graphics.cpp
@@ -26,7 +26,5 @@ FX_ERR CAGG_Graphics::Create(CFX_Graphics* owner,
}
CAGG_Graphics::~CAGG_Graphics() {
- if (m_owner->m_renderDevice)
- delete (CFX_FxgeDevice*)m_owner->m_renderDevice;
- m_owner = nullptr;
+ delete m_owner->m_renderDevice;
}
« no previous file with comments | « xfa/fxfa/parser/xfa_script_resolveprocessor.cpp ('k') | xfa/fxgraphics/cfx_path_generator.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698