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

Unified Diff: core/src/fpdfdoc/doc_basic.cpp

Issue 1243953004: Re-land else-after-returns (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 5 years, 5 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/src/fpdfdoc/doc_ap.cpp ('k') | core/src/fpdfdoc/doc_form.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/src/fpdfdoc/doc_basic.cpp
diff --git a/core/src/fpdfdoc/doc_basic.cpp b/core/src/fpdfdoc/doc_basic.cpp
index 9d31d156245e844b51f82a1cc99636a875081de3..3ba109b016999cce78a02247f8cc5faeec31b62b 100644
--- a/core/src/fpdfdoc/doc_basic.cpp
+++ b/core/src/fpdfdoc/doc_basic.cpp
@@ -148,13 +148,12 @@ static CPDF_Object* SearchNameNode(CPDF_Dictionary* pNode, int nIndex, int& nCur
if (nIndex >= nCurIndex + nCount) {
nCurIndex += nCount;
return NULL;
- } else {
- if (ppFind != NULL) {
- *ppFind = pNames;
- }
- csName = pNames->GetString((nIndex - nCurIndex) * 2);
- return pNames->GetElementValue((nIndex - nCurIndex) * 2 + 1);
}
+ if (ppFind != NULL) {
+ *ppFind = pNames;
+ }
+ csName = pNames->GetString((nIndex - nCurIndex) * 2);
+ return pNames->GetElementValue((nIndex - nCurIndex) * 2 + 1);
}
CPDF_Array* pKids = pNode->GetArray(FX_BSTRC("Kids"));
if (pKids == NULL) {
« no previous file with comments | « core/src/fpdfdoc/doc_ap.cpp ('k') | core/src/fpdfdoc/doc_form.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698