From 9cbbbb9c34cc6a6041478e9c5a850f19257b7f6a Mon Sep 17 00:00:00 2001 From: Sevan Janiyan Date: Thu, 23 Nov 2023 18:49:18 +0000 Subject: [PATCH] Use __attribute__((malloc(free))) only with GCC >= 11 --- utils.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils.h b/utils.h index 1147ebb..ee2880f 100644 --- a/utils.h +++ b/utils.h @@ -24,7 +24,7 @@ # define NONNULL # define UNUSED #endif -#if defined __GNUC__ && !defined __clang__ +#if (defined __GNUC__ && __GNUC__ >= 11) && !defined __clang__ # define MALLOC_FREE __attribute__((malloc(free))) #else # define MALLOC_FREE