diff --git a/net-mail/mailutils/files/mailutils-3.19-format-security.patch b/net-mail/mailutils/files/mailutils-3.19-format-security.patch new file mode 100644 index 0000000000000..2c49817a3b11d --- /dev/null +++ b/net-mail/mailutils/files/mailutils-3.19-format-security.patch @@ -0,0 +1,36 @@ +From 9379ec9e25ae6bdbd3d6f5ef9930ac2176d2efe7 Mon Sep 17 00:00:00 2001 +From: Jordi Mallach +Date: Wed, 5 Mar 2025 12:13:06 +0100 +Subject: Fix missing format arguments for builds with -Wformat-security + +libmailutils/diag/debug.c (mu_debug_format_spec): Add missing "%s" to +printf to avoid triggering -Wformat-security. +--- + libmailutils/diag/debug.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/libmailutils/diag/debug.c b/libmailutils/diag/debug.c +index 2a1b52e..84c921a 100644 +--- a/libmailutils/diag/debug.c ++++ b/libmailutils/diag/debug.c +@@ -511,7 +511,7 @@ mu_debug_format_spec (mu_stream_t str, const char *names, int flags) + { + if (delim) + { +- rc = mu_stream_printf (str, delim); ++ rc = mu_stream_printf (str, "%s", delim); + if (rc) + break; + } +@@ -564,7 +564,7 @@ mu_debug_format_spec (mu_stream_t str, const char *names, int flags) + { + if (delim) + { +- rc = mu_stream_printf (str, delim); ++ rc = mu_stream_printf (str, "%s", delim); + if (rc) + break; + } +-- +cgit v1.1 + diff --git a/net-mail/mailutils/mailutils-3.19.ebuild b/net-mail/mailutils/mailutils-3.19.ebuild index 2e1a21f4002f8..e00a959d23389 100644 --- a/net-mail/mailutils/mailutils-3.19.ebuild +++ b/net-mail/mailutils/mailutils-3.19.ebuild @@ -63,6 +63,7 @@ REQUIRED_USE=" DOCS=( ABOUT-NLS AUTHORS COPYING COPYING.LESSER ChangeLog INSTALL NEWS README THANKS TODO ) PATCHES=( "${FILESDIR}"/${PN}-3.5-add-include.patch + "${FILESDIR}"/${PN}-3.19-format-security.patch ) pkg_setup() {