mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 16:49:39 -05:00
Check some mdb integer type assumptions
This commit is contained in:
parent
88da18cccf
commit
69e53cf700
1 changed files with 7 additions and 0 deletions
|
|
@ -48,6 +48,7 @@
|
|||
|
||||
#include <assert.h>
|
||||
#include <errno.h>
|
||||
#include <limits.h>
|
||||
#include <stddef.h>
|
||||
#include <stdint.h>
|
||||
#include <stdio.h>
|
||||
|
|
@ -63,6 +64,12 @@
|
|||
#include "mdb.h"
|
||||
#include "midl.h"
|
||||
|
||||
#if (__BYTE_ORDER == __LITTLE_ENDIAN) == (__BYTE_ORDER == __BIG_ENDIAN)
|
||||
# error "Unknown or unsupported endianness (__BYTE_ORDER)"
|
||||
#elif (-6 & 5) || CHAR_BIT != 8 || UINT_MAX < 0xffffffff || ULONG_MAX % 0xFFFF
|
||||
# error "Two's complement, reasonably sized integer types, please"
|
||||
#endif
|
||||
|
||||
/** @defgroup internal MDB Internals
|
||||
* @{
|
||||
*/
|
||||
|
|
|
|||
Loading…
Reference in a new issue