|
|
|
@ -39,8 +39,8 @@ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* NOTE: These are the table sizes calculated through the specs. */ |
|
|
|
|
#define CPAL_V0_HEADER_BASE_SIZE 12 |
|
|
|
|
#define COLOR_SIZE 4 |
|
|
|
|
#define CPAL_V0_HEADER_BASE_SIZE 12U |
|
|
|
|
#define COLOR_SIZE 4U |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* all data from `CPAL' not covered in FT_Palette_Data */ |
|
|
|
@ -139,7 +139,7 @@ |
|
|
|
|
3U * 4 > table_size ) |
|
|
|
|
goto InvalidTable; |
|
|
|
|
|
|
|
|
|
p += face->palette_data.num_palettes * 2; |
|
|
|
|
p += face->palette_data.num_palettes * 2U; |
|
|
|
|
|
|
|
|
|
type_offset = FT_NEXT_ULONG( p ); |
|
|
|
|
label_offset = FT_NEXT_ULONG( p ); |
|
|
|
@ -149,7 +149,7 @@ |
|
|
|
|
{ |
|
|
|
|
if ( type_offset >= table_size ) |
|
|
|
|
goto InvalidTable; |
|
|
|
|
if ( face->palette_data.num_palettes * 2 > |
|
|
|
|
if ( face->palette_data.num_palettes * 2U > |
|
|
|
|
table_size - type_offset ) |
|
|
|
|
goto InvalidTable; |
|
|
|
|
|
|
|
|
@ -170,7 +170,7 @@ |
|
|
|
|
{ |
|
|
|
|
if ( label_offset >= table_size ) |
|
|
|
|
goto InvalidTable; |
|
|
|
|
if ( face->palette_data.num_palettes * 2 > |
|
|
|
|
if ( face->palette_data.num_palettes * 2U > |
|
|
|
|
table_size - label_offset ) |
|
|
|
|
goto InvalidTable; |
|
|
|
|
|
|
|
|
@ -191,7 +191,7 @@ |
|
|
|
|
{ |
|
|
|
|
if ( entry_label_offset >= table_size ) |
|
|
|
|
goto InvalidTable; |
|
|
|
|
if ( face->palette_data.num_palette_entries * 2 > |
|
|
|
|
if ( face->palette_data.num_palette_entries * 2U > |
|
|
|
|
table_size - entry_label_offset ) |
|
|
|
|
goto InvalidTable; |
|
|
|
|
|
|
|
|
|