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

Issue 1902953002: Remove a few more char* members from structs/classes. (Closed)

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

Description

Remove a few more char* members from structs/classes. This is a result of looking for the anti-paterns /char\*\sm_/ and /m_.*=.*\.c_str/ which indicate that a class may be using the contents of a string without extending the lifetime of the underlying storage. Along the way, change to uint8_t in fx_dib; this is unrelated but avoids grep hits (it is binary, not chars anyways). Also remove two string operators that make it easy to assign in a manner that does not extend contents lifetime. Committed: https://pdfium.googlesource.com/pdfium/+/4d31d0c653cf66f72bdef7cebbf7cff45d33f6c6

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+14 lines, -28 lines) Patch
M core/fpdfdoc/doc_form.cpp View 2 chunks +8 lines, -6 lines 0 comments Download
M core/fxcrt/include/fx_string.h View 4 chunks +0 lines, -16 lines 0 comments Download
M core/fxge/dib/dib_int.h View 1 chunk +2 lines, -2 lines 0 comments Download
M xfa/fxfa/app/xfa_textlayout.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M xfa/fxfa/parser/xfa_document_imp.cpp View 1 chunk +1 line, -1 line 0 comments Download
M xfa/fxfa/parser/xfa_object_imp.cpp View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 9 (5 generated)
Tom Sepez
Lei, for review. Follow-up based on pattern in previous bug.
4 years, 8 months ago (2016-04-19 20:36:02 UTC) #4
Lei Zhang
lgtm
4 years, 8 months ago (2016-04-19 21:10:24 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1902953002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1902953002/1
4 years, 8 months ago (2016-04-19 21:11:44 UTC) #7
commit-bot: I haz the power
4 years, 8 months ago (2016-04-19 21:12:06 UTC) #9
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://pdfium.googlesource.com/pdfium/+/4d31d0c653cf66f72bdef7cebbf7cff45d33...

Powered by Google App Engine
This is Rietveld 408576698