diff options
author | Tom Sepez <tsepez@chromium.org> | 2015-05-20 09:50:37 -0700 |
---|---|---|
committer | Tom Sepez <tsepez@chromium.org> | 2015-05-20 09:50:37 -0700 |
commit | d50b172a9d3a05704748f0798b5aaa422485abbd (patch) | |
tree | 0289d99b370b8526c539fc676004bf622f5228a3 /core/src/fpdfdoc | |
parent | 90a4181194dd8eca153cf2a101ec27e382b27a58 (diff) | |
download | pdfium-d50b172a9d3a05704748f0798b5aaa422485abbd.tar.xz |
Merge to XFA: Remove FX_Alloc() null checks now that it can't return NULL.
Original Review URL: https://codereview.chromium.org/1142713005
R=thestig@chromium.org
TBR=thestig@chromium.org
Review URL: https://codereview.chromium.org/1143663008
Diffstat (limited to 'core/src/fpdfdoc')
-rw-r--r-- | core/src/fpdfdoc/doc_annot.cpp | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/core/src/fpdfdoc/doc_annot.cpp b/core/src/fpdfdoc/doc_annot.cpp index 3285487ca0..c8151bfa04 100644 --- a/core/src/fpdfdoc/doc_annot.cpp +++ b/core/src/fpdfdoc/doc_annot.cpp @@ -345,9 +345,6 @@ CPDF_PageObject* CPDF_Annot::GetBorder(FX_BOOL bPrint, const CPDF_RenderOptions* dash_count ++; } pGraphState->m_DashArray = FX_Alloc(FX_FLOAT, dash_count); - if (pGraphState->m_DashArray == NULL) { - return NULL; - } pGraphState->m_DashCount = dash_count; FX_DWORD i; for (i = 0; i < pDashArray->GetCount(); i ++) { @@ -358,9 +355,6 @@ CPDF_PageObject* CPDF_Annot::GetBorder(FX_BOOL bPrint, const CPDF_RenderOptions* } } else { pGraphState->m_DashArray = FX_Alloc(FX_FLOAT, 2); - if (pGraphState->m_DashArray == NULL) { - return NULL; - } pGraphState->m_DashCount = 2; pGraphState->m_DashArray[0] = pGraphState->m_DashArray[1] = 3 * 1.0f; } @@ -447,9 +441,6 @@ void CPDF_Annot::DrawBorder(CFX_RenderDevice* pDevice, const CFX_AffineMatrix* p dash_count ++; } graph_state.m_DashArray = FX_Alloc(FX_FLOAT, dash_count); - if (graph_state.m_DashArray == NULL) { - return ; - } graph_state.m_DashCount = dash_count; FX_DWORD i; for (i = 0; i < pDashArray->GetCount(); i ++) { @@ -460,9 +451,6 @@ void CPDF_Annot::DrawBorder(CFX_RenderDevice* pDevice, const CFX_AffineMatrix* p } } else { graph_state.m_DashArray = FX_Alloc(FX_FLOAT, 2); - if (graph_state.m_DashArray == NULL) { - return ; - } graph_state.m_DashCount = 2; graph_state.m_DashArray[0] = graph_state.m_DashArray[1] = 3 * 1.0f; } |