diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2016-02-29 14:03:09 -0500 |
---|---|---|
committer | Dan Sinclair <dsinclair@chromium.org> | 2016-02-29 14:03:09 -0500 |
commit | a74e9c9d3b0d98c5d6042d7ca739cd921a4524db (patch) | |
tree | 6d19df6011716727dfcc59f4ef902331de813db3 /xfa/src/fgas | |
parent | a5585569e274fcff8ae106e412eb764c2787cb3f (diff) | |
download | pdfium-a74e9c9d3b0d98c5d6042d7ca739cd921a4524db.tar.xz |
Using size_t to silence warnings.
Change a couple int32_t's to size_t in order to fix warnings on OSX.
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1747793002 .
Diffstat (limited to 'xfa/src/fgas')
-rw-r--r-- | xfa/src/fgas/src/font/fx_stdfontmgr.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/xfa/src/fgas/src/font/fx_stdfontmgr.cpp b/xfa/src/fgas/src/font/fx_stdfontmgr.cpp index b363ccbdd7..6ad4918203 100644 --- a/xfa/src/fgas/src/font/fx_stdfontmgr.cpp +++ b/xfa/src/fgas/src/font/fx_stdfontmgr.cpp @@ -485,11 +485,12 @@ const FX_CHAR* g_FontFolders[] = { "/system/fonts", #endif }; + CFX_FontSourceEnum_File::CFX_FontSourceEnum_File() { - for (int32_t i = 0; i < sizeof(g_FontFolders) / sizeof(const FX_CHAR*); i++) { + for (size_t i = 0; i < FX_ArraySize(g_FontFolders); ++i) m_FolderPaths.Add(g_FontFolders[i]); - } } + CFX_ByteString CFX_FontSourceEnum_File::GetNextFile() { Restart: void* pCurHandle = @@ -1119,11 +1120,9 @@ static const FX_BitCodePage g_Bit2CodePage[] = { }; FX_WORD FX_GetCodePageBit(FX_WORD wCodePage) { - for (int32_t i = 0; i < sizeof(g_Bit2CodePage) / sizeof(FX_BitCodePage); - i++) { - if (g_Bit2CodePage[i].wCodePage == wCodePage) { + for (size_t i = 0; i < FX_ArraySize(g_Bit2CodePage); ++i) { + if (g_Bit2CodePage[i].wCodePage == wCodePage) return g_Bit2CodePage[i].wBit; - } } return (FX_WORD)-1; } |