Index: src/cff.cc |
diff --git a/src/cff.cc b/src/cff.cc |
index a9368df5efe0cbc6980e62aa301249a74ba6d027..7866614ced2cf27830be5bcf83ec01064008efad 100644 |
--- a/src/cff.cc |
+++ b/src/cff.cc |
@@ -472,7 +472,7 @@ bool ParseDictData(const uint8_t *data, size_t table_length, |
FONT_FORMAT font_format = FORMAT_UNKNOWN; |
bool have_ros = false; |
- size_t glyphs = 0; |
+ uint16_t glyphs = 0; |
size_t charset_offset = 0; |
while (table.offset() < dict_length) { |
@@ -692,7 +692,7 @@ bool ParseDictData(const uint8_t *data, size_t table_length, |
return OTS_FAILURE(); |
} |
if (format == 0) { |
- for (size_t j = 0; j < glyphs; ++j) { |
+ for (uint16_t j = 0; j < glyphs; ++j) { |
uint8_t fd_index = 0; |
if (!table.ReadU8(&fd_index)) { |
return OTS_FAILURE(); |
@@ -836,7 +836,7 @@ bool ParseDictData(const uint8_t *data, size_t table_length, |
} |
switch (format) { |
case 0: |
- for (unsigned j = 1 /* .notdef is omitted */; j < glyphs; ++j) { |
+ for (uint16_t j = 1 /* .notdef is omitted */; j < glyphs; ++j) { |
uint16_t sid = 0; |
if (!table.ReadU16(&sid)) { |
return OTS_FAILURE(); |