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

Issue 1972053003: Add CFX_ByteStringC::CharAt() to avoid c_str() and casts (Closed)

Created:
4 years, 7 months ago by Tom Sepez
Modified:
4 years, 7 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

Add CFX_ByteStringC::CharAt() to avoid c_str() and casts. Most of the time, we want to operate on chars as if they were unsigned, but there are a few places where we need the default (questionably signed) values. Consolidate the casting in a single place rather than forcing callers to get a char* ptr. BUG=pdfium:493 Committed: https://pdfium.googlesource.com/pdfium/+/28c7844c1ef5ea0c8727b890e9ff56b593119a00

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+52 lines, -68 lines) Patch
M core/fpdfapi/fpdf_font/cpdf_font.cpp View 1 chunk +1 line, -1 line 0 comments Download
M core/fpdfapi/fpdf_font/fpdf_font.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M core/fpdfapi/fpdf_parser/fpdf_parser_utility.cpp View 1 chunk +4 lines, -5 lines 0 comments Download
M core/fxcrt/fx_basic_bstring.cpp View 1 chunk +1 line, -2 lines 0 comments Download
M core/fxcrt/fx_basic_gcc.cpp View 1 chunk +2 lines, -3 lines 0 comments Download
M core/fxcrt/fx_basic_util.cpp View 3 chunks +20 lines, -22 lines 0 comments Download
M core/fxcrt/fx_extension.cpp View 1 chunk +4 lines, -8 lines 0 comments Download
M core/fxcrt/fx_xml_composer.cpp View 1 chunk +7 lines, -13 lines 0 comments Download
M core/fxcrt/include/fx_string.h View 1 chunk +3 lines, -0 lines 0 comments Download
M xfa/fee/fde_txtedtengine.cpp View 3 chunks +5 lines, -9 lines 0 comments Download
M xfa/fxbarcode/datamatrix/BC_DataMatrixDecodedBitStreamParser.cpp View 1 chunk +3 lines, -3 lines 0 comments Download

Messages

Total messages: 9 (5 generated)
Tom Sepez
Lei, for review.
4 years, 7 months ago (2016-05-12 18:54:22 UTC) #3
Lei Zhang
lgtm I changed the BUG= line so it doesn't point to an ancient Chromium bug.
4 years, 7 months ago (2016-05-12 22:47:26 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1972053003/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1972053003/1
4 years, 7 months ago (2016-05-12 22:52:02 UTC) #7
commit-bot: I haz the power
4 years, 7 months ago (2016-05-12 22:52:18 UTC) #9
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://pdfium.googlesource.com/pdfium/+/28c7844c1ef5ea0c8727b890e9ff56b59311...

Powered by Google App Engine
This is Rietveld 408576698