From 146c24461395d0752f9e79973827f78d084f7d6f Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Fri, 3 Apr 2015 12:53:36 -0700 Subject: [PATCH] Only Windows doesn't have %zd. Change-Id: Ie09619df212cf7c8aa18a6d46c3e6b6ca3f478cf --- include/utils/Compat.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/include/utils/Compat.h b/include/utils/Compat.h index ca4a8e0d8..7d9631027 100644 --- a/include/utils/Compat.h +++ b/include/utils/Compat.h @@ -41,12 +41,12 @@ static inline ssize_t pread64(int fd, void* buf, size_t nbytes, off64_t offset) #define DEFFILEMODE 0666 #endif /* _WIN32 */ -#if HAVE_PRINTF_ZD -# define ZD "%zd" -# define ZD_TYPE ssize_t +#if defined(_WIN32) +#define ZD "%ld" +#define ZD_TYPE long #else -# define ZD "%ld" -# define ZD_TYPE long +#define ZD "%zd" +#define ZD_TYPE ssize_t #endif /*