shithub: jbig2

Download patch

ref: d79efba4fb7d95a2d3a118164ed526fad0ffc9e4
parent: 98742e58fcbeef4562db413e1d3533cffaa0fbee
author: Sebastian Rasmussen <sebras@gmail.com>
date: Sat Jul 14 14:19:47 EDT 2018

jbig2dec: Untie fix for Visual Studio from Microsoft's compiler.

The i32 suffix is specific for MSVC, but can be avoided.
gssprintf.c for APR_INT32_MAX and APR_INT32_MIN also leaves out
the suffix out. This is legal because the default integer literal
size is large enough to fit 32 bit signed integers.

--- a/jbig2_arith_int.c
+++ b/jbig2_arith_int.c
@@ -32,11 +32,11 @@
 #include "jbig2_arith.h"
 #include "jbig2_arith_int.h"
 
-#ifndef INT32_MAX
-#define INT32_MAX        2147483647i32
+#if !defined (INT32_MIN)
+#define INT32_MIN (-0x7fffffff - 1)
 #endif
-#ifndef INT32_MIN
-#define INT32_MIN        (-2147483647i32 - 1)
+#if !defined (INT32_MAX)
+#define INT32_MAX  0x7fffffff
 #endif
 
 struct _Jbig2ArithIntCtx {