Changes in src/libcfa/libhdr/libdebug.h [aa3d77b:4aa2fb2]
- File:
-
- 1 edited
-
src/libcfa/libhdr/libdebug.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/libcfa/libhdr/libdebug.h
raa3d77b r4aa2fb2 18 18 19 19 #ifdef __CFA_DEBUG__ 20 #define LIB_DEBUG_DO( ...) __VA_ARGS__21 #define LIB_NO_DEBUG_DO( ...)20 #define LIB_DEBUG_DO(x) x 21 #define LIB_NO_DEBUG_DO(x) ((void)0) 22 22 #else 23 #define LIB_DEBUG_DO( ...)24 #define LIB_NO_DEBUG_DO( ...) __VA_ARGS__23 #define LIB_DEBUG_DO(x) ((void)0) 24 #define LIB_NO_DEBUG_DO(x) x 25 25 #endif 26 26 … … 51 51 52 52 #ifdef __CFA_DEBUG_PRINT__ 53 #define LIB_DEBUG_WRITE( fd, buffer, len ) __lib_debug_write( fd, buffer, len ) 54 #define LIB_DEBUG_ACQUIRE() __lib_debug_acquire() 55 #define LIB_DEBUG_RELEASE() __lib_debug_release() 56 #define LIB_DEBUG_PRINT_SAFE(...) __lib_debug_print_safe (__VA_ARGS__) 57 #define LIB_DEBUG_PRINT_NOLOCK(...) __lib_debug_print_nolock (__VA_ARGS__) 58 #define LIB_DEBUG_PRINT_BUFFER(...) __lib_debug_print_buffer (__VA_ARGS__) 59 #define LIB_DEBUG_PRINT_BUFFER_DECL(fd, ...) char text[256]; int len = snprintf( text, 256, __VA_ARGS__ ); __lib_debug_write( fd, text, len ); 60 #define LIB_DEBUG_PRINT_BUFFER_LOCAL(fd, ...) len = snprintf( text, 256, __VA_ARGS__ ); __lib_debug_write( fd, text, len ); 53 #define LIB_DEBUG_WRITE( fd, buffer, len ) __lib_debug_write( fd, buffer, len ) 54 #define LIB_DEBUG_ACQUIRE() __lib_debug_acquire() 55 #define LIB_DEBUG_RELEASE() __lib_debug_release() 56 #define LIB_DEBUG_PRINT_SAFE(...) __lib_debug_print_safe (__VA_ARGS__) 57 #define LIB_DEBUG_PRINT_NOLOCK(...) __lib_debug_print_nolock (__VA_ARGS__) 58 #define LIB_DEBUG_PRINT_BUFFER(...) __lib_debug_print_buffer (__VA_ARGS__) 61 59 #else 62 #define LIB_DEBUG_WRITE(...) ((void)0) 63 #define LIB_DEBUG_ACQUIRE() ((void)0) 64 #define LIB_DEBUG_RELEASE() ((void)0) 65 #define LIB_DEBUG_PRINT_SAFE(...) ((void)0) 66 #define LIB_DEBUG_PRINT_NOLOCK(...) ((void)0) 67 #define LIB_DEBUG_PRINT_BUFFER(...) ((void)0) 68 #define LIB_DEBUG_PRINT_BUFFER_DECL(...) ((void)0) 69 #define LIB_DEBUG_PRINT_BUFFER_LOCAL(...) ((void)0) 60 #define LIB_DEBUG_WRITE(...) ((void)0) 61 #define LIB_DEBUG_ACQUIRE() ((void)0) 62 #define LIB_DEBUG_RELEASE() ((void)0) 63 #define LIB_DEBUG_PRINT_SAFE(...) ((void)0) 64 #define LIB_DEBUG_PRINT_NOLOCK(...) ((void)0) 65 #define LIB_DEBUG_PRINT_BUFFER(...) ((void)0) 70 66 #endif 71 67
Note:
See TracChangeset
for help on using the changeset viewer.