From: David Lamparter Date: Mon, 12 Apr 2021 22:52:55 +0000 (+0200) Subject: lib: fix printf format on NetBSD X-Git-Tag: base_8.1~398^2 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=ca846ff82c5ed74cd5d71f316d4a3e428655cc1f;p=mirror%2Ffrr.git lib: fix printf format on NetBSD *sigh*. It doesn't accept `%m` otherwise. Signed-off-by: David Lamparter --- diff --git a/lib/compiler.h b/lib/compiler.h index bbfe01b569..8b8ec08c25 100644 --- a/lib/compiler.h +++ b/lib/compiler.h @@ -356,7 +356,11 @@ extern "C" { #define PRIx64 "Lx" #else /* !_FRR_ATTRIBUTE_PRINTFRR */ +#ifdef __NetBSD__ +#define PRINTFRR(a, b) __attribute__((format(gnu_syslog, a, b))) +#else #define PRINTFRR(a, b) __attribute__((format(printf, a, b))) +#endif /* frr-format plugin is C-only for now, so no point in doing these shenanigans * for C++... (also they can break some C++ stuff...)