Skip to content

Commit 4178ddc

Browse files
committed
Changed readcount so that _TIFFSetGetType can identify the type
1 parent 18ee51a commit 4178ddc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libImaging/TiffDecode.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,7 @@ int ImagingLibTiffDecode(Imaging im, ImagingCodecState state, UINT8* buffer, Py_
378378
TIFFClose(tiff);
379379
return -1;
380380
}
381-
381+
382382
state->bytes = row_byte_size * tile_length;
383383

384384
if (TIFFTileSize(tiff) > state->bytes) {
@@ -578,7 +578,7 @@ int ImagingLibTiffMergeFieldInfo(ImagingCodecState state, TIFFDataType field_typ
578578

579579
// custom fields added with ImagingLibTiffMergeFieldInfo are only used for
580580
// decoding, ignore readcount;
581-
int readcount = 0;
581+
int readcount = 1;
582582
// we support writing a single value, or a variable number of values
583583
int writecount = 1;
584584
// whether the first value should encode the number of values.

0 commit comments

Comments
 (0)