summaryrefslogtreecommitdiff
path: root/include/mupdf/fitz/system.h
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2016-06-08 12:42:57 +0100
committerRobin Watts <robin.watts@artifex.com>2016-06-08 13:53:56 +0100
commit2fd7f11cfe4ebdc6d1035db521e61d15101ab36e (patch)
treecf18d3cc3ab606b4f22684ef4ea2ea3f06d41602 /include/mupdf/fitz/system.h
parentfea0f8467f983cc5c1075d19787a4b398d0d5e22 (diff)
downloadmupdf-2fd7f11cfe4ebdc6d1035db521e61d15101ab36e.tar.xz
Move to using size_t for all mallocs.
This has knock on effects in the store. fix
Diffstat (limited to 'include/mupdf/fitz/system.h')
-rw-r--r--include/mupdf/fitz/system.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/mupdf/fitz/system.h b/include/mupdf/fitz/system.h
index be5504a5..72d17c83 100644
--- a/include/mupdf/fitz/system.h
+++ b/include/mupdf/fitz/system.h
@@ -199,6 +199,15 @@ typedef int fz_off_t;
#define fz_atoo_imp atoi
#endif
+/* Portable way to format a size_t */
+#if defined(_WIN64)
+#define FMT_zu "%Iu"
+#elif defined(_WIN32)
+#define FMT_zu "%u"
+#else
+#define FMT_zu "%zu"
+#endif
+
#ifdef __ANDROID__
#include <android/log.h>
#define LOG_TAG "libmupdf"