summaryrefslogtreecommitdiff
path: root/xfa/fxbarcode/pdf417/BC_PDF417.cpp
diff options
context:
space:
mode:
authorthestig <thestig@chromium.org>2016-06-09 18:39:33 -0700
committerCommit bot <commit-bot@chromium.org>2016-06-09 18:39:33 -0700
commit6dc1d7753691c0ff2f390e8ffd95a3182064487e (patch)
tree43d77664973a76c107832ae7b3c3e0f04bba1fe0 /xfa/fxbarcode/pdf417/BC_PDF417.cpp
parentfcf61b39ee597c73e80ba789833fb7fe49878422 (diff)
downloadpdfium-6dc1d7753691c0ff2f390e8ffd95a3182064487e.tar.xz
Get rid of NULLs in xfa/fxbarcode/
Review-Url: https://codereview.chromium.org/2048983002
Diffstat (limited to 'xfa/fxbarcode/pdf417/BC_PDF417.cpp')
-rw-r--r--xfa/fxbarcode/pdf417/BC_PDF417.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/xfa/fxbarcode/pdf417/BC_PDF417.cpp b/xfa/fxbarcode/pdf417/BC_PDF417.cpp
index 908901c04e..317a1cb92b 100644
--- a/xfa/fxbarcode/pdf417/BC_PDF417.cpp
+++ b/xfa/fxbarcode/pdf417/BC_PDF417.cpp
@@ -390,7 +390,7 @@ CBC_PDF417::CBC_PDF417() {
m_maxCols = 30;
m_maxRows = 90;
m_minRows = 3;
- m_barcodeMatrix = NULL;
+ m_barcodeMatrix = nullptr;
}
CBC_PDF417::CBC_PDF417(FX_BOOL compact) {
m_compact = compact;
@@ -399,7 +399,7 @@ CBC_PDF417::CBC_PDF417(FX_BOOL compact) {
m_maxCols = 30;
m_maxRows = 90;
m_minRows = 3;
- m_barcodeMatrix = NULL;
+ m_barcodeMatrix = nullptr;
}
CBC_PDF417::~CBC_PDF417() {
@@ -539,7 +539,7 @@ CFX_Int32Array* CBC_PDF417::determineDimensions(
int32_t errorCorrectionCodeWords,
int32_t& e) {
FX_FLOAT ratio = 0.0f;
- CFX_Int32Array* dimension = NULL;
+ CFX_Int32Array* dimension = nullptr;
for (int32_t cols = m_minCols; cols <= m_maxCols; cols++) {
int32_t rows =
calculateNumberOfRows(sourceCodeWords, errorCorrectionCodeWords, cols);
@@ -561,7 +561,7 @@ CFX_Int32Array* CBC_PDF417::determineDimensions(
dimension->Add(cols);
dimension->Add(rows);
}
- if (dimension == NULL) {
+ if (!dimension) {
int32_t rows = calculateNumberOfRows(sourceCodeWords,
errorCorrectionCodeWords, m_minCols);
if (rows < m_minRows) {
@@ -574,9 +574,9 @@ CFX_Int32Array* CBC_PDF417::determineDimensions(
dimension->Add(rows);
}
}
- if (dimension == NULL) {
+ if (!dimension) {
e = BCExceptionUnableToFitMessageInColumns;
- return NULL;
+ return nullptr;
}
return dimension;
}