mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-10 21:23:58 +01:00
Move sizeof check to torint.h
This commit is contained in:
parent
9529d99982
commit
68260e85b5
@ -125,4 +125,13 @@ typedef int32_t ssize_t;
|
||||
/** Any size_t larger than this amount is likely to be an underflow. */
|
||||
#define SIZE_T_CEILING ((size_t)(SSIZE_MAX-16))
|
||||
|
||||
#if SIZEOF_INT > SIZEOF_VOID_P
|
||||
#error "sizeof(int) > sizeof(void *) - Tor cannot be built on this platform!"
|
||||
#endif
|
||||
|
||||
#if SIZEOF_UNSIGNED_INT > SIZEOF_VOID_P
|
||||
#error "sizeof(unsigned int) > sizeof(void *) - Tor cannot be built on this \
|
||||
platform!"
|
||||
#endif
|
||||
|
||||
#endif /* !defined(TOR_TORINT_H) */
|
||||
|
@ -11,15 +11,6 @@
|
||||
#include <stdint.h>
|
||||
#include <limits.h>
|
||||
|
||||
#if SIZEOF_INT > SIZEOF_VOID_P
|
||||
#error "sizeof(int) > sizeof(void *) - Tor cannot be built on this platform!"
|
||||
#endif
|
||||
|
||||
#if SIZEOF_UNSIGNED_INT > SIZEOF_VOID_P
|
||||
#error "sizeof(unsigned int) > sizeof(void *) - Tor cannot be built on this \
|
||||
platform!"
|
||||
#endif
|
||||
|
||||
/** Assert that <b>a</b> can be cast to void * and back. */
|
||||
static void
|
||||
assert_int_voidptr_roundtrip(int a)
|
||||
|
Loading…
Reference in New Issue
Block a user