summaryrefslogtreecommitdiff
path: root/core/fxcrt/fx_string.cpp
diff options
context:
space:
mode:
authorRyan Harrison <rharrison@chromium.org>2017-09-27 10:53:11 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-09-27 16:11:38 +0000
commit875e98c581952478f3a3ccef9b2f2e3ed06c5346 (patch)
tree8e0d7e032056bf4c73d6da43c0f3ce4eadb74dfd /core/fxcrt/fx_string.cpp
parentcc3a3ee3ebcc1baabdfa7ffca5876dbbfa3980c1 (diff)
downloadpdfium-875e98c581952478f3a3ccef9b2f2e3ed06c5346.tar.xz
Remove FX_STRSIZE and replace with size_t
BUG=pdfium:828 Change-Id: I5c40237433ebabaeabdb43aec9cdf783e41dfe16 Reviewed-on: https://pdfium-review.googlesource.com/13230 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Diffstat (limited to 'core/fxcrt/fx_string.cpp')
-rw-r--r--core/fxcrt/fx_string.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/fxcrt/fx_string.cpp b/core/fxcrt/fx_string.cpp
index ce4e187837..233c5e64b7 100644
--- a/core/fxcrt/fx_string.cpp
+++ b/core/fxcrt/fx_string.cpp
@@ -62,7 +62,7 @@ class CFX_UTF8Encoder {
} // namespace
ByteString FX_UTF8Encode(const WideStringView& wsStr) {
- FX_STRSIZE len = wsStr.GetLength();
+ size_t len = wsStr.GetLength();
const wchar_t* pStr = wsStr.unterminated_c_str();
CFX_UTF8Encoder encoder;
while (len-- > 0)
@@ -99,7 +99,7 @@ bool FX_atonum(const ByteStringView& strc, void* pData) {
pdfium::base::CheckedNumeric<uint32_t> integer = 0;
bool bNegative = false;
bool bSigned = false;
- FX_STRSIZE cc = 0;
+ size_t cc = 0;
if (strc[0] == '+') {
cc++;
bSigned = true;
@@ -184,7 +184,7 @@ float FX_atof(const WideStringView& wsStr) {
return FX_atof(FX_UTF8Encode(wsStr).c_str());
}
-FX_STRSIZE FX_ftoa(float d, char* buf) {
+size_t FX_ftoa(float d, char* buf) {
buf[0] = '0';
buf[1] = '\0';
if (d == 0.0f) {
@@ -208,13 +208,13 @@ FX_STRSIZE FX_ftoa(float d, char* buf) {
return 1;
}
char buf2[32];
- FX_STRSIZE buf_size = 0;
+ size_t buf_size = 0;
if (bNegative) {
buf[buf_size++] = '-';
}
int i = scaled / scale;
FXSYS_itoa(i, buf2, 10);
- FX_STRSIZE len = FXSYS_strlen(buf2);
+ size_t len = FXSYS_strlen(buf2);
memcpy(buf + buf_size, buf2, len);
buf_size += len;
int fraction = scaled % scale;