20 lines
881 B
Diff
20 lines
881 B
Diff
|
diff --git a/libtiff/tif_write.c b/libtiff/tif_write.c
|
||
|
index 586f6fdff66a7a0c1864dbe1e2c5831602b055ce..a31ecd12c133ac18bed6bfbc97fcbad5e19a3257 100644
|
||
|
--- a/libtiff/tif_write.c
|
||
|
+++ b/libtiff/tif_write.c
|
||
|
@@ -538,9 +538,11 @@ TIFFSetupStrips(TIFF* tif)
|
||
|
if (td->td_planarconfig == PLANARCONFIG_SEPARATE)
|
||
|
td->td_stripsperimage /= td->td_samplesperpixel;
|
||
|
td->td_stripoffset = (uint64 *)
|
||
|
- _TIFFmalloc(td->td_nstrips * sizeof (uint64));
|
||
|
+ _TIFFCheckMalloc(tif, td->td_nstrips, sizeof (uint64),
|
||
|
+ "for \"StripOffsets\" array");
|
||
|
td->td_stripbytecount = (uint64 *)
|
||
|
- _TIFFmalloc(td->td_nstrips * sizeof (uint64));
|
||
|
+ _TIFFCheckMalloc(tif, td->td_nstrips, sizeof (uint64),
|
||
|
+ "for \"StripByteCounts\" array");
|
||
|
if (td->td_stripoffset == NULL || td->td_stripbytecount == NULL)
|
||
|
return (0);
|
||
|
/*
|
||
|
|