20 #include <platform/mem.h>
22 #ifdef KAA_TRACE_MEMORY_ALLOCATIONS
30 void * kaa_trace_memory_allocs_malloc(
size_t s,
const char *file,
int line);
31 void * kaa_trace_memory_allocs_calloc(
size_t n,
size_t s,
const char *file,
int line);
32 void kaa_trace_memory_allocs_free(
void * p,
const char *file,
int line);
33 void kaa_trace_memory_allocs_set_logger(
kaa_logger_t *logger);
35 #define KAA_MALLOC(S) kaa_trace_memory_allocs_malloc(S, __FILE__, __LINE__)
36 #define KAA_CALLOC(N,S) kaa_trace_memory_allocs_calloc((N), (S), __FILE__, __LINE__)
37 #define KAA_FREE(P) kaa_trace_memory_allocs_free((P), __FILE__, __LINE__)
43 #else // defined KAA_TRACE_MEMORY_ALLOCATIONS
46 #define KAA_MALLOC(S) __KAA_MALLOC(S)
47 #define KAA_CALLOC(N,S) __KAA_CALLOC(N,S)
48 #define KAA_REALLOC(P,S) __KAA_REALLOC(P,S)
49 #define KAA_FREE(P) __KAA_FREE(P)
52 #endif // defined KAA_TRACE_MEMORY_ALLOCATIONS
struct kaa_logger_t kaa_logger_t
Definition: kaa_log.h:68
Simple logger for Kaa C Endpoint.