replace SKIPWS with a proper inline func with the right API.
[apps/madmutt.git] / smime.c
diff --git a/smime.c b/smime.c
index a5d2fbc..5a8f7e7 100644 (file)
--- a/smime.c
+++ b/smime.c
@@ -83,10 +83,19 @@ static char SmimeIntermediateToUse[_POSIX_PATH_MAX];
 
 
 /*
- *     Queries and passphrase handling.
+ * Create a format string to be used with scanf.
+ * To use it, write, for instance, MUTT_FORMAT(HUGE_STRING).
+ * 
+ * See K&R 2nd ed, p. 231 for an explanation.
  */
+#define _MUTT_FORMAT_2(a,b)    "%" a  b
+#define _MUTT_FORMAT_1(a, b)   _MUTT_FORMAT_2(#a, b)
+#define MUTT_FORMAT(a)         _MUTT_FORMAT_1(a, "s")
 
 
+/*
+ *     Queries and passphrase handling.
+ */
 
 
 /* these are copies from pgp.c */