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

Unified Diff: core/fpdfdoc/cpdf_annotlist.cpp

Issue 2453163002: Take advantage of implicit std::unique_ptr<>(nulltpr_t) ctor. (Closed)
Patch Set: Created 4 years, 2 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/fpdfapi/render/fpdf_render_pattern.cpp ('k') | fpdfsdk/fpdf_progressive.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fpdfdoc/cpdf_annotlist.cpp
diff --git a/core/fpdfdoc/cpdf_annotlist.cpp b/core/fpdfdoc/cpdf_annotlist.cpp
index b626115de19238d3d75dd9763d455dbe7bcf8757..4821f8e6dd6b2b1680d4c853cc98f6868c44a490 100644
--- a/core/fpdfdoc/cpdf_annotlist.cpp
+++ b/core/fpdfdoc/cpdf_annotlist.cpp
@@ -25,13 +25,13 @@ std::unique_ptr<CPDF_Annot> CreatePopupAnnot(CPDF_Annot* pAnnot,
CPDF_Document* pDocument) {
CPDF_Dictionary* pParentDict = pAnnot->GetAnnotDict();
if (!pParentDict)
- return std::unique_ptr<CPDF_Annot>();
+ return nullptr;
// TODO(jaepark): We shouldn't strip BOM for some strings and not for others.
// See pdfium:593.
CFX_WideString sContents = pParentDict->GetUnicodeTextFor("Contents");
if (sContents.IsEmpty())
- return std::unique_ptr<CPDF_Annot>();
+ return nullptr;
CPDF_Dictionary* pAnnotDict =
new CPDF_Dictionary(pDocument->GetByteStringPool());
« no previous file with comments | « core/fpdfapi/render/fpdf_render_pattern.cpp ('k') | fpdfsdk/fpdf_progressive.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698