From ff874612bad325e2f6b44ae895fa8d9628c4fd44 Mon Sep 17 00:00:00 2001 From: Farkal Date: Mon, 10 Aug 2020 15:32:47 +0200 Subject: [PATCH] Allow to decode LONG8 (u64) TileOffsets and TileByteCounts have the LONG8 type on bigtiff. --- src/decoder/ifd.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/decoder/ifd.rs b/src/decoder/ifd.rs index 79c9e72..fae499a 100644 --- a/src/decoder/ifd.rs +++ b/src/decoder/ifd.rs @@ -343,6 +343,9 @@ impl Entry { (Type::SRATIONAL, n) => self.decode_offset(n, bo, limits, decoder, |decoder| { Ok(SRational(decoder.read_slong()?, decoder.read_slong()?)) }), + (Type::LONG8, n) => self.decode_offset(n, bo, limits, decoder, |decoder| { + Ok(UnsignedBig(decoder.read_long8()?)) + }), (Type::ASCII, n) => { let n = usize::try_from(n)?; if n > limits.decoding_buffer_size {