Go to the documentation of this file.
17 #ifndef AVRO_PRIVATE_H
18 #define AVRO_PRIVATE_H
33 #define snprintf _snprintf
40 #define AVRO_PLATFORM_IS_BIG_ENDIAN (0)
42 #include <sys/param.h>
43 #if BYTE_ORDER == BIG_ENDIAN
44 #define AVRO_PLATFORM_IS_BIG_ENDIAN (1)
46 #define AVRO_PLATFORM_IS_BIG_ENDIAN (0)
57 #define check(rval, call) { rval = call; if(rval) return rval; }
59 #define check_set(rval, call, ...) \
67 #define check_prefix(rval, call, ...) \
75 #define check_param(result, test, name) \
82 #define AVRO_UNUSED(var) (void)var;
84 #define container_of(ptr_, type_, member_) \
85 ((type_ *)((char *)ptr_ - (size_t)&((type_ *)0)->member_))
87 #define nullstrcmp(s1, s2) \
88 (((s1) && (s2)) ? strcmp(s1, s2) : ((s1) || (s2)))