* src/base/ftstream.c (FT_Stream_ReadFields): Switch to FT_Offset.

This commit is contained in:
Alexei Podtelezhnikov 2024-08-05 13:02:04 +00:00
parent a48cdddef3
commit e181911d87

View File

@ -763,10 +763,10 @@
case ft_frame_bytes: /* read a byte sequence */
case ft_frame_skip: /* skip some bytes */
{
FT_Int len = fields->size;
FT_Offset len = fields->size;
if ( len > stream->limit - cursor )
if ( len > (FT_Offset)( stream->limit - cursor ) )
{
error = FT_THROW( Invalid_Stream_Operation );
goto Exit;