From c60de04ff82b6232f702b40fea1c7fd0876ba29f Mon Sep 17 00:00:00 2001 From: Sebastian Rasmussen Date: Tue, 27 Sep 2016 17:11:35 +0800 Subject: Bug 697166: tiff: Avoid freeing offset/bytecount arrays twice. --- source/fitz/load-tiff.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source/fitz/load-tiff.c') diff --git a/source/fitz/load-tiff.c b/source/fitz/load-tiff.c index 59b86b92..ca3b71cc 100644 --- a/source/fitz/load-tiff.c +++ b/source/fitz/load-tiff.c @@ -1024,12 +1024,16 @@ fz_decode_tiff_samples(fz_context *ctx, struct tiff *tiff) { tiff->tileoffsets = tiff->stripoffsets; tiff->tileoffsetslen = tiff->stripoffsetslen; + tiff->stripoffsets = NULL; + tiff->stripoffsetslen = 0; } if (!tiff->tilebytecounts && !tiff->tilebytecountslen && tiff->stripbytecounts && tiff->stripbytecountslen) { tiff->tilebytecounts = tiff->stripbytecounts; tiff->tilebytecountslen = tiff->stripbytecountslen; + tiff->stripbytecounts = NULL; + tiff->stripbytecountslen = 0; } } -- cgit v1.2.3