mirror of
https://github.com/webmproject/libwebp.git
synced 2024-11-19 20:08:28 +01:00
tiffdec: restore libtiff 3.9.x compatibility
use tsize_t which is equivalent (for now) to tmsize_t added in version 4 Change-Id: I7489ef7b39d9a3692a4b952de22476b245240ed1
This commit is contained in:
parent
b2f77b57a9
commit
31ca2a8098
@ -153,9 +153,9 @@ int ReadTIFF(const uint8_t* const data, size_t data_size,
|
||||
}
|
||||
// _Tiffmalloc uses a signed type for size.
|
||||
alloc_size = (int64_t)((uint64_t)width * height * sizeof(*raster));
|
||||
if (alloc_size < 0 || alloc_size != (tmsize_t)alloc_size) goto End;
|
||||
if (alloc_size < 0 || alloc_size != (tsize_t)alloc_size) goto End;
|
||||
|
||||
raster = (uint32*)_TIFFmalloc((tmsize_t)alloc_size);
|
||||
raster = (uint32*)_TIFFmalloc((tsize_t)alloc_size);
|
||||
if (raster != NULL) {
|
||||
if (TIFFReadRGBAImageOriented(tif, width, height, raster,
|
||||
ORIENTATION_TOPLEFT, 1)) {
|
||||
|
Loading…
Reference in New Issue
Block a user