summaryrefslogtreecommitdiff
path: root/xfa/fgas/crt/fgas_utils.h
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-06-23 12:40:16 -0700
committerCommit bot <commit-bot@chromium.org>2016-06-23 12:40:16 -0700
commit85d1f2c2f9f1e746bedb1b6f03576613f54fbc27 (patch)
treeff5b393fb9b89f006327bee7bc8c955522defb67 /xfa/fgas/crt/fgas_utils.h
parent6e12478cb298c3a8277493ee79ae0b73d6df8554 (diff)
downloadpdfium-85d1f2c2f9f1e746bedb1b6f03576613f54fbc27.tar.xz
Remove NULL in xfa/
This CL converts all NULL's to nullptr. All instances of comparison to nullptr have been removed. Review-Url: https://codereview.chromium.org/2095653002
Diffstat (limited to 'xfa/fgas/crt/fgas_utils.h')
-rw-r--r--xfa/fgas/crt/fgas_utils.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/xfa/fgas/crt/fgas_utils.h b/xfa/fgas/crt/fgas_utils.h
index f01d115b3e..0cf853fa70 100644
--- a/xfa/fgas/crt/fgas_utils.h
+++ b/xfa/fgas/crt/fgas_utils.h
@@ -378,7 +378,7 @@ class CFX_DiscreteArrayTemplate : public CFX_BaseDiscreteArray {
: CFX_BaseDiscreteArray(iChunkSize, sizeof(baseType)) {}
baseType& GetAt(int32_t index, const baseType& defValue) const {
baseType* p = (baseType*)CFX_BaseDiscreteArray::GetAt(index);
- return p == NULL ? (baseType&)defValue : *p;
+ return p ? *p : (baseType&)defValue;
}
baseType* GetPtrAt(int32_t index) const {
return (baseType*)CFX_BaseDiscreteArray::GetAt(index);
@@ -447,7 +447,7 @@ class CFX_ObjectStackTemplate : public CFX_BaseStack {
}
void Pop() {
baseType* p = (baseType*)CFX_BaseStack::GetTopElement();
- if (p != NULL) {
+ if (p) {
p->~baseType();
}
CFX_BaseStack::Pop();