From: Christian Brauner Date: Wed, 11 Aug 2021 13:43:18 +0000 (+0200) Subject: memory_utils: make cleanup handler as unused X-Git-Tag: lxc-4.0.11~220 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=14f8022a5918ad7bde723fa2eb5b612e0e38fbfa;p=thirdparty%2Flxc.git memory_utils: make cleanup handler as unused They are sometimes used to just clean something up automatically at end of scope but the variables themselves might not be actually used. Signed-off-by: Christian Brauner --- diff --git a/src/lxc/memory_utils.h b/src/lxc/memory_utils.h index 7e4d0541f..f2352a175 100644 --- a/src/lxc/memory_utils.h +++ b/src/lxc/memory_utils.h @@ -20,7 +20,8 @@ cleaner(*ptr); \ } -#define call_cleaner(cleaner) __attribute__((__cleanup__(cleaner##_function))) +#define call_cleaner(cleaner) \ + __attribute__((__cleanup__(cleaner##_function))) __attribute__((unused)) #define close_prot_errno_disarm(fd) \ if (fd >= 0) { \