aboutsummaryrefslogtreecommitdiffstats
path: root/common.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--common.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/common.h b/common.h
index 4953da2..c573719 100644
--- a/common.h
+++ b/common.h
@@ -44,9 +44,18 @@
#ifdef NEED_EXPLICIT_BZERO
static void *(*volatile my_explicit_memset)(void *, int, size_t) = memset;
-static __attribute__((__optimize__("-O0"))) void
+
+# if defined(__clang__)
+# pragma clang diagnostic push
+# pragma clang diagnostic ignored "-Wunknown-attributes"
+# endif
+__attribute__((__optimize__("-O0")))
+static void
my_explicit_bzero(void *ptr, size_t size)
{
(*my_explicit_memset)(ptr, 0, size);
}
+# if defined(__clang__)
+# pragma clang diagnostic pop
+# endif
#endif