On Mon, Dec 05, 2016 at 11:24:37AM +0100, Jordi Mallach wrote:
> Did you have a chance to test-compile using -Wformat-security? It's a
> default GCC option in quite a few distributions these days.

The attached trivial patch fixes this.

Additionally, I'm attaching some spelling fixes.

-- 
Jordi Mallach Pérez  --  Debian developer     http://www.debian.org/
[email protected]     [email protected]     http://www.sindominio.net/
GnuPG public key information available at http://oskuro.net/
From d9b71362a7fd0726bde87f0d4a1b4ddb3accda4a Mon Sep 17 00:00:00 2001
From: Jordi Mallach <[email protected]>
Date: Fri, 9 Dec 2016 12:17:03 +0100
Subject: [PATCH 1/2] Fix spelling errors.

---
 examples/nntpclient.c | 2 +-
 imap4d/uid.c          | 2 +-
 mail/mailvar.c        | 2 +-
 mu/shell.c            | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/examples/nntpclient.c b/examples/nntpclient.c
index 1e53b864..4b3da10b 100644
--- a/examples/nntpclient.c
+++ b/examples/nntpclient.c
@@ -953,7 +953,7 @@ com_info (char *arg)
 
   if (!printed)
     {
-      printf ("No commands match `%s'.  Possibilties are:\n", arg);
+      printf ("No commands match `%s'.  Possibilities are:\n", arg);
 
       for (i = 0; commands[i].name; i++)
 	{
diff --git a/imap4d/uid.c b/imap4d/uid.c
index 97f8088c..bc5d7b58 100644
--- a/imap4d/uid.c
+++ b/imap4d/uid.c
@@ -49,7 +49,7 @@ imap4d_uid (struct imap4d_session *session,
     rc = imap4d_search0 (tok, 1, &err_text);
   else
     {
-      err_text = "Uknown uid command";
+      err_text = "Unknown uid command";
       rc = RESP_BAD;
     }
   return io_completion_response (command, rc, "%s %s", cmd, err_text);
diff --git a/mail/mailvar.c b/mail/mailvar.c
index 803f32cc..4643620f 100644
--- a/mail/mailvar.c
+++ b/mail/mailvar.c
@@ -121,7 +121,7 @@ struct mailvar_symbol mailvar_tab[] =
       N_("input message is terminated with a dot alone on a line") },
     { { "editheaders", },
       MAILVAR_TYPEMASK (mailvar_type_boolean),
-      N_("allow to edit message headers while composing") },
+      N_("allow editting message headers while composing") },
     { { "emptystart", },
       MAILVAR_TYPEMASK (mailvar_type_boolean),
       N_("start interactive mode if the mailbox is empty") },
diff --git a/mu/shell.c b/mu/shell.c
index ff4bd055..276057bf 100644
--- a/mu/shell.c
+++ b/mu/shell.c
@@ -226,7 +226,7 @@ shell_help (int argc, char **argv)
 	print_comtab (mu_strout, com);
       else
 	{
-	  mu_printf ("No commands match `%s'.  Possibilties are:\n", name);
+	  mu_printf ("No commands match `%s'.  Possibilities are:\n", name);
 	  list_commands (shell_comtab, name);
 	}
     }
-- 
2.11.0

From 9510feb3d911fb9a8c2e9109d116ced9a2cceada Mon Sep 17 00:00:00 2001
From: Jordi Mallach <[email protected]>
Date: Fri, 9 Dec 2016 12:17:44 +0100
Subject: [PATCH 2/2] Fix build when building with -Werror -Wformat-security.

---
 libmailutils/string/wordsplit.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libmailutils/string/wordsplit.c b/libmailutils/string/wordsplit.c
index b570ccf1..bdf6d352 100644
--- a/libmailutils/string/wordsplit.c
+++ b/libmailutils/string/wordsplit.c
@@ -2335,7 +2335,7 @@ mu_wordsplit_perror (struct mu_wordsplit *wsp)
       break;
 
     default:
-      wsp->ws_error (mu_wordsplit_strerror (wsp));
+      wsp->ws_error ("%s", mu_wordsplit_strerror (wsp));
     }
 }
 
-- 
2.11.0

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Bug-mailutils mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-mailutils

Reply via email to