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

Issue 1960673003: Replace some calls to Release() with direct delete, part 1. (Closed)

Created:
4 years, 7 months ago by Tom Sepez
Modified:
4 years, 7 months ago
Reviewers:
Wei Li, weili
CC:
pdfium-reviews_googlegroups.com
Base URL:
https://pdfium.googlesource.com/pdfium.git@master
Target Ref:
refs/heads/master
Project:
pdfium
Visibility:
Public.

Description

Replace some calls to Release() with direct delete, part 1. Searching for the anti-pattern: void Release() { delete this; } We must be explicit on the ownership model. Add unique_ptrs as a result. Committed: https://pdfium.googlesource.com/pdfium/+/f74ad998d2e8d2636fb25e94823946a3b151e34e

Patch Set 1 #

Patch Set 2 : Stray files. #

Patch Set 3 : More stray files #

Patch Set 4 : Rebase #

Patch Set 5 : Stray file (again) #

Patch Set 6 : Stray file (again again) #

Patch Set 7 : Rebase #

Patch Set 8 : Add unique ptrs #

Total comments: 5

Patch Set 9 : Rebase #

Patch Set 10 : Another unique_ptr. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+171 lines, -210 lines) Patch
M core/fxcodec/codec/fx_codec_flate.cpp View 1 chunk +0 lines, -1 line 0 comments Download
M core/fxcodec/codec/fx_codec_jpeg.cpp View 1 chunk +0 lines, -1 line 0 comments Download
M xfa/fde/cfde_path.h View 1 chunk +0 lines, -2 lines 0 comments Download
M xfa/fde/css/fde_cssstyleselector.h View 1 chunk +1 line, -3 lines 0 comments Download
M xfa/fde/css/fde_cssstyleselector.cpp View 1 2 3 4 5 6 7 2 chunks +31 lines, -32 lines 0 comments Download
M xfa/fde/css/fde_cssstylesheet.cpp View 1 2 3 4 5 6 7 2 chunks +12 lines, -9 lines 0 comments Download
M xfa/fde/css/fde_csssyntax.h View 1 chunk +1 line, -2 lines 0 comments Download
M xfa/fde/fde_gedevice.h View 1 chunk +1 line, -3 lines 0 comments Download
M xfa/fde/fde_iterator.h View 1 chunk +1 line, -3 lines 0 comments Download
M xfa/fde/fde_render.h View 1 2 3 4 5 6 7 3 chunks +5 lines, -4 lines 0 comments Download
M xfa/fde/fde_render.cpp View 1 2 3 4 5 6 7 5 chunks +7 lines, -13 lines 0 comments Download
M xfa/fde/tto/fde_textout.h View 1 2 3 4 5 6 7 3 chunks +4 lines, -3 lines 0 comments Download
M xfa/fde/tto/fde_textout.cpp View 1 2 3 4 5 6 7 8 9 6 chunks +18 lines, -26 lines 0 comments Download
M xfa/fee/fde_txtedtengine.cpp View 1 2 3 4 5 6 7 3 chunks +2 lines, -2 lines 0 comments Download
M xfa/fwl/basewidget/fwl_editimp.cpp View 1 2 3 4 5 6 7 3 chunks +8 lines, -6 lines 0 comments Download
M xfa/fwl/theme/cfwl_widgettp.h View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M xfa/fwl/theme/cfwl_widgettp.cpp View 1 2 3 4 5 6 7 5 chunks +15 lines, -16 lines 0 comments Download
M xfa/fxfa/app/xfa_ffwidgetacc.cpp View 1 2 3 4 5 6 7 6 chunks +29 lines, -46 lines 0 comments Download
M xfa/fxfa/app/xfa_fwltheme.h View 1 2 3 4 5 6 7 2 chunks +3 lines, -1 line 0 comments Download
M xfa/fxfa/app/xfa_fwltheme.cpp View 1 2 3 4 5 6 7 4 chunks +3 lines, -9 lines 0 comments Download
M xfa/fxfa/app/xfa_textlayout.h View 1 2 3 4 5 6 7 3 chunks +3 lines, -2 lines 0 comments Download
M xfa/fxfa/app/xfa_textlayout.cpp View 1 2 3 4 5 6 7 11 chunks +26 lines, -25 lines 0 comments Download

Messages

Total messages: 12 (7 generated)
Tom Sepez
Wei, for review. Thanks. https://codereview.chromium.org/1960673003/diff/140001/xfa/fde/css/fde_cssstyleselector.cpp File xfa/fde/css/fde_cssstyleselector.cpp (left): https://codereview.chromium.org/1960673003/diff/140001/xfa/fde/css/fde_cssstyleselector.cpp#oldcode544 xfa/fde/css/fde_cssstyleselector.cpp:544: int32_t iLen; note: these two ...
4 years, 7 months ago (2016-05-06 21:41:14 UTC) #4
Wei Li
lgtm https://codereview.chromium.org/1960673003/diff/140001/xfa/fde/tto/fde_textout.cpp File xfa/fde/tto/fde_textout.cpp (right): https://codereview.chromium.org/1960673003/diff/140001/xfa/fde/tto/fde_textout.cpp#newcode909 xfa/fde/tto/fde_textout.cpp:909: delete pPath; Nit: why not use unique_ptr for ...
4 years, 7 months ago (2016-05-06 22:01:21 UTC) #6
Tom Sepez
https://codereview.chromium.org/1960673003/diff/140001/xfa/fde/tto/fde_textout.cpp File xfa/fde/tto/fde_textout.cpp (right): https://codereview.chromium.org/1960673003/diff/140001/xfa/fde/tto/fde_textout.cpp#newcode909 xfa/fde/tto/fde_textout.cpp:909: delete pPath; On 2016/05/06 22:01:21, Wei Li wrote: > ...
4 years, 7 months ago (2016-05-11 17:05:39 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1960673003/180001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1960673003/180001
4 years, 7 months ago (2016-05-11 17:13:30 UTC) #10
commit-bot: I haz the power
4 years, 7 months ago (2016-05-11 17:26:10 UTC) #12
Message was sent while issue was closed.
Committed patchset #10 (id:180001) as
https://pdfium.googlesource.com/pdfium/+/f74ad998d2e8d2636fb25e94823946a3b151...

Powered by Google App Engine
This is Rietveld 408576698