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

Unified Diff: core/include/fxcrt/fx_basic.h

Issue 1747123002: Fix and enable lint checks. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 10 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 | « core/include/fpdfapi/fpdf_resource.h ('k') | core/include/fxcrt/fx_memory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/include/fxcrt/fx_basic.h
diff --git a/core/include/fxcrt/fx_basic.h b/core/include/fxcrt/fx_basic.h
index 6e092dd540befec4e9775f97ec9bf60e5e482be8..006b2b377d3bf0186e3f8232a66b12d64944cd6a 100644
--- a/core/include/fxcrt/fx_basic.h
+++ b/core/include/fxcrt/fx_basic.h
@@ -315,13 +315,12 @@ class CFX_ArrayTemplate : public CFX_BasicArray {
TYPE* GetData() { return (TYPE*)m_pData; }
FX_BOOL SetAtGrow(int nIndex, TYPE newElement) {
- if (nIndex < 0) {
+ if (nIndex < 0)
return FALSE;
- }
- if (nIndex >= m_nSize)
- if (!SetSize(nIndex + 1)) {
- return FALSE;
- }
+
+ if (nIndex >= m_nSize && !SetSize(nIndex + 1))
+ return FALSE;
+
((TYPE*)m_pData)[nIndex] = newElement;
return TRUE;
}
« no previous file with comments | « core/include/fpdfapi/fpdf_resource.h ('k') | core/include/fxcrt/fx_memory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698