Skip to content

Commit fb3d4be

Browse files
committed
exif/heic: Make offset size_t
1 parent 6cc1a11 commit fb3d4be

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

ext/exif/exif.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4393,12 +4393,11 @@ static bool exif_scan_HEIF_header(image_info_type *ImageInfo, unsigned char *buf
43934393
isobmff_box_type box;
43944394
isobmff_item_pos_type pos;
43954395
unsigned char *data;
4396-
off_t offset;
43974396
uint64_t limit;
43984397
int box_header_size, remain;
43994398
bool ret = false;
44004399

4401-
for (offset = php_ifd_get32u(buf, 1); ImageInfo->FileSize - 16 > offset; offset += box.size) {
4400+
for (size_t offset = php_ifd_get32u(buf, 1); ImageInfo->FileSize - 16 > offset; offset += box.size) {
44024401
if ((php_stream_seek(ImageInfo->infile, offset, SEEK_SET) < 0) ||
44034402
(exif_read_from_stream_file_looped(ImageInfo->infile, (char*)buf, 16) != 16)) {
44044403
break;

0 commit comments

Comments
 (0)