shithub: jbig2

Download patch

ref: f741b92938efb8283ad51aa71d5ae1af9505bbd5
parent: e6bea5d638a547edb30542eb08882318f2c3a444
author: Sebastian Rasmussen <sebras@gmail.com>
date: Sun Jul 1 09:18:48 EDT 2018

jbig2dec: Use already parsed size of page association field.

--- a/jbig2_segment.c
+++ b/jbig2_segment.c
@@ -112,7 +112,7 @@
     }
 
     /* 7.2.6 */
-    if (result->flags & 0x40) {
+    if (pa_size == 4) {
         result->page_association = jbig2_get_uint32(buf + offset);
         offset += 4;
     } else {