summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2020-01-07 23:13:11 +0100
committerEven Rouault <even.rouault@spatialys.com>2020-01-07 23:13:11 +0100
commit0a8245b7b81e4b2cf9841b81c6fcc252b8fe6162 (patch)
treea416125eb1805ac951cc66bc18a0e2ee1a82a8d8
parent4f6db6a12971cea851094dca560669c61044a999 (diff)
downloadlibtiff-git-0a8245b7b81e4b2cf9841b81c6fcc252b8fe6162.tar.gz
OJPEGReadHeaderInfo: if rowsperstrip not defined, then assume one-single-strip. Complementary fix to 0356ea76bac908c61160d735f078437ace953bd3
-rw-r--r--libtiff/tif_ojpeg.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libtiff/tif_ojpeg.c b/libtiff/tif_ojpeg.c
index d6f7d97e..aa5ff5e2 100644
--- a/libtiff/tif_ojpeg.c
+++ b/libtiff/tif_ojpeg.c
@@ -1064,6 +1064,8 @@ OJPEGReadHeaderInfo(TIFF* tif)
{
sp->strile_width=sp->image_width;
sp->strile_length=tif->tif_dir.td_rowsperstrip;
+ if( sp->strile_length == (uint32)-1 )
+ sp->strile_length = sp->image_length;
sp->strile_length_total=sp->image_length;
}
if (tif->tif_dir.td_samplesperpixel==1)