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

Issue 2571913002: Avoid the ptr.reset(new XXX()) anti-pattern (Closed)

Created:
4 years ago by Tom Sepez
Modified:
4 years ago
Reviewers:
dsinclair
CC:
pdfium-reviews_googlegroups.com
Target Ref:
refs/heads/master
Project:
pdfium
Visibility:
Public.

Description

Avoid the ptr.reset(new XXX()) anti-pattern Be suspicious of |new|. This removes some of the easy cases. Review-Url: https://codereview.chromium.org/2571913002 Committed: https://pdfium.googlesource.com/pdfium/+/a9caab94c1f16929e5acf2676117224617d80f53

Patch Set 1 #

Patch Set 2 : iwyu #

Patch Set 3 : rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+237 lines, -179 lines) Patch
M core/fpdfapi/cpdf_modulemgr.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/edit/fpdf_edit_create.cpp View 1 3 chunks +3 lines, -2 lines 0 comments Download
M core/fpdfapi/font/cpdf_cidfont.cpp View 1 3 chunks +3 lines, -2 lines 0 comments Download
M core/fpdfapi/font/cpdf_font.cpp View 2 chunks +6 lines, -6 lines 0 comments Download
M core/fpdfapi/font/fpdf_font.cpp View 1 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/page/cpdf_contentparser.cpp View 1 6 chunks +8 lines, -7 lines 0 comments Download
M core/fpdfapi/page/cpdf_form.cpp View 1 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/page/cpdf_page.cpp View 1 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/page/cpdf_tilingpattern.cpp View 1 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/page/fpdf_page_func.cpp View 1 3 chunks +6 lines, -5 lines 0 comments Download
M core/fpdfapi/parser/cpdf_document_unittest.cpp View 1 chunk +1 line, -1 line 0 comments Download
M core/fpdfapi/parser/cpdf_parser.cpp View 1 3 chunks +3 lines, -2 lines 0 comments Download
M core/fpdfapi/parser/cpdf_stream.cpp View 1 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/render/cpdf_devicebuffer.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/render/cpdf_imagerenderer.cpp View 1 2 chunks +3 lines, -2 lines 0 comments Download
M core/fpdfapi/render/cpdf_progressiverenderer.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/render/cpdf_renderstatus.cpp View 1 5 chunks +5 lines, -4 lines 0 comments Download
M core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfapi/render/fpdf_render_loadimage.cpp View 1 2 5 chunks +6 lines, -5 lines 0 comments Download
M core/fpdfdoc/cpdf_variabletext.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M core/fpdfdoc/cpvt_sectioninfo.cpp View 2 chunks +4 lines, -2 lines 0 comments Download
M core/fpdfdoc/cpvt_wordinfo.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M core/fxcodec/codec/fx_codec_jbig.cpp View 3 chunks +4 lines, -3 lines 0 comments Download
M core/fxcodec/jbig2/JBig2_Context.cpp View 1 18 chunks +56 lines, -53 lines 0 comments Download
M core/fxcodec/jbig2/JBig2_HtrdProc.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M core/fxcodec/jbig2/JBig2_SddProc.cpp View 4 chunks +5 lines, -4 lines 0 comments Download
M core/fxcodec/jbig2/JBig2_TrdProc.cpp View 2 chunks +11 lines, -10 lines 0 comments Download
M fpdfsdk/fpdfdoc.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M fpdfsdk/fpdfdoc_unittest.cpp View 1 chunk +2 lines, -1 line 0 comments Download
M xfa/fde/cfde_txtedtengine.cpp View 1 chunk +1 line, -1 line 0 comments Download
M xfa/fde/cfde_txtedtpage.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fde/cfx_wordbreak.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fde/css/fde_cssstyleselector.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fde/fde_render.cpp View 3 chunks +3 lines, -2 lines 0 comments Download
M xfa/fde/tto/fde_textout.cpp View 2 chunks +3 lines, -2 lines 0 comments Download
M xfa/fgas/layout/fgas_textbreak.cpp View 2 chunks +3 lines, -2 lines 0 comments Download
M xfa/fwl/cfwl_combobox.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M xfa/fwl/cfwl_datetimepicker.cpp View 1 chunk +2 lines, -1 line 0 comments Download
M xfa/fwl/cfwl_widgetmgr.cpp View 1 chunk +1 line, -1 line 0 comments Download
M xfa/fwl/theme/cfwl_checkboxtp.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fwl/theme/cfwl_widgettp.cpp View 3 chunks +3 lines, -2 lines 0 comments Download
M xfa/fxbarcode/BC_TwoDimWriter.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fxbarcode/common/reedsolomon/BC_ReedSolomonGF256.cpp View 2 chunks +4 lines, -2 lines 0 comments Download
M xfa/fxbarcode/oned/BC_OneDimWriter.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fxbarcode/oned/BC_OnedUPCAWriter.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fxbarcode/pdf417/BC_PDF417.cpp View 2 chunks +3 lines, -1 line 0 comments Download
M xfa/fxfa/app/xfa_ffapp.cpp View 1 5 chunks +6 lines, -5 lines 0 comments Download
M xfa/fxfa/app/xfa_ffdoc.cpp View 1 3 chunks +5 lines, -5 lines 0 comments Download
M xfa/fxfa/app/xfa_ffdocview.cpp View 1 2 chunks +4 lines, -3 lines 0 comments Download
M xfa/fxfa/app/xfa_ffwidgetacc.cpp View 1 2 5 chunks +13 lines, -11 lines 0 comments Download
M xfa/fxfa/app/xfa_fontmgr.cpp View 1 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fxfa/app/xfa_textlayout.cpp View 1 2 4 chunks +4 lines, -3 lines 0 comments Download
M xfa/fxfa/parser/cxfa_document_parser.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fxfa/parser/cxfa_node.cpp View 2 chunks +3 lines, -2 lines 0 comments Download
M xfa/fxfa/parser/cxfa_scriptcontext.cpp View 2 chunks +3 lines, -1 line 0 comments Download
M xfa/fxgraphics/cfx_graphics.cpp View 2 chunks +2 lines, -1 line 0 comments Download
M xfa/fxgraphics/cfx_path.cpp View 2 chunks +2 lines, -1 line 0 comments Download

Messages

Total messages: 17 (13 generated)
Tom Sepez
Dan, ready for review.
4 years ago (2016-12-13 21:34:57 UTC) #9
dsinclair
lgtm
4 years ago (2016-12-14 13:56:48 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2571913002/40001
4 years ago (2016-12-14 13:56:56 UTC) #14
commit-bot: I haz the power
4 years ago (2016-12-14 13:57:14 UTC) #17
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as
https://pdfium.googlesource.com/pdfium/+/a9caab94c1f16929e5acf2676117224617d8...

Powered by Google App Engine
This is Rietveld 408576698