diff --git a/configure.ac b/configure.ac index 0ebf823..d29a387 100644 --- a/configure.ac +++ b/configure.ac @@ -173,6 +173,7 @@ AX_COMPILE_CHECK_SIZEOF(int) AX_COMPILE_CHECK_SIZEOF(long) AX_COMPILE_CHECK_SIZEOF(long long) AX_COMPILE_CHECK_SIZEOF(size_t, [#include ]) +AX_COMPILE_CHECK_SIZEOF(int64_t, [#include ]) AC_CONFIG_FILES([ Makefile diff --git a/json_object.c b/json_object.c index 01ee0a8..9ffb149 100644 --- a/json_object.c +++ b/json_object.c @@ -33,6 +33,10 @@ #include "strdup_compat.h" #include "snprintf_compat.h" +#if SIZEOF_LONG_LONG != SIZEOF_INT64_T +#error "The long long type isn't 64-bits" +#endif + // Don't define this. It's not thread-safe. /* #define REFCOUNT_DEBUG 1 */