X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fcommon%2Fmacros.h;h=308d3d57a14d5ff9ad7911383af9f40f0477c4da;hb=81527d36f84a02110360f0332f3b35f2d3024d17;hp=fc159c0af3c707102d7bb853a49360d16e01c1d1;hpb=331744e34f56a5aec69b05d356d6901e67926acc;p=lttng-tools.git diff --git a/src/common/macros.h b/src/common/macros.h index fc159c0af..308d3d57a 100644 --- a/src/common/macros.h +++ b/src/common/macros.h @@ -46,7 +46,11 @@ /* * Memory allocation zeroed */ -#define zmalloc(x) calloc(1, x) +static inline +void *zmalloc(size_t len) +{ + return calloc(1, len); +} #ifndef ARRAY_SIZE #define ARRAY_SIZE(array) (sizeof(array) / (sizeof((array)[0])))