X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fcommon%2Fmacros.h;h=c521aacd5f3df8f582502ce8faa9f29feb1c9063;hp=33ada7321801a14b438a27dca246ec8fbfb0c897;hb=d0927b411543c173c4fb83abf785fd71a9d29ed1;hpb=4b223a6755662f272f7db155ee380528728e5dd1 diff --git a/src/common/macros.h b/src/common/macros.h index 33ada7321..c521aacd5 100644 --- a/src/common/macros.h +++ b/src/common/macros.h @@ -79,6 +79,10 @@ void *zmalloc(size_t len) #define min(a, b) ((a) < (b) ? (a) : (b)) #endif +#ifndef min_t +#define min_t(type, a, b) ((type) min(a, b)) +#endif + #ifndef LTTNG_PACKED #define LTTNG_PACKED __attribute__((__packed__)) #endif