summaryrefslogtreecommitdiff
path: root/src/systemd
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2018-11-20 04:34:08 +0100
committerYu Watanabe <watanabe.yu+github@gmail.com>2018-11-20 12:34:08 +0900
commit012c2f761bf1eb0b9c784b867293f7f1c17c3080 (patch)
treef21082dff2a0f17ac8cbbe13eddd256fad2731db /src/systemd
parent52048013b7869a8c0ef5a1b70d3bb0f9b69a4e7c (diff)
downloadsystemd-012c2f761bf1eb0b9c784b867293f7f1c17c3080.tar.gz
tree-wide: use __ prefixed gcc attributes (#10843)
As suggest here: https://gcc.gnu.org/onlinedocs/gcc/Attribute-Syntax.html#Attribute-Syntax "You may optionally specify attribute names with ‘__’ preceding and following the name. This allows you to use them in header files without being concerned about a possible macro of the same name. For example, you may use the attribute name __noreturn__ instead of noreturn. "
Diffstat (limited to 'src/systemd')
-rw-r--r--src/systemd/_sd-common.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/systemd/_sd-common.h b/src/systemd/_sd-common.h
index 4742b2e742..b026b5c551 100644
--- a/src/systemd/_sd-common.h
+++ b/src/systemd/_sd-common.h
@@ -25,22 +25,22 @@
#ifndef _sd_printf_
# if __GNUC__ >= 4
-# define _sd_printf_(a,b) __attribute__ ((format (printf, a, b)))
+# define _sd_printf_(a,b) __attribute__ ((__format__(printf, a, b)))
# else
# define _sd_printf_(a,b)
# endif
#endif
#ifndef _sd_sentinel_
-# define _sd_sentinel_ __attribute__((sentinel))
+# define _sd_sentinel_ __attribute__((__sentinel__))
#endif
#ifndef _sd_packed_
-# define _sd_packed_ __attribute__((packed))
+# define _sd_packed_ __attribute__((__packed__))
#endif
#ifndef _sd_pure_
-# define _sd_pure_ __attribute__((pure))
+# define _sd_pure_ __attribute__((__pure__))
#endif
#ifndef _SD_STRINGIFY