]> diplodocus.org Git - nmh/blobdiff - sbr/mf.c
Merge remote-tracking branch 'origin' into xoauth
[nmh] / sbr / mf.c
index 6adbba72b408e1656ba3ca1d9b1246298c5d987c..c11b0c10e8d87f2029f7567eb0d7a096bb33016e 100644 (file)
--- a/sbr/mf.c
+++ b/sbr/mf.c
@@ -65,7 +65,7 @@ isat (const char *p)
  * getadrx() implements a partial 822-style address parser.  The parser
  * is neither complete nor correct.  It does however recognize nearly all
  * of the 822 address syntax.  In addition it handles the majority of the
- * 733 syntax as well.  Most problems arise from trying to accomodate both.
+ * 733 syntax as well.  Most problems arise from trying to accommodate both.
  *
  * In terms of 822, the route-specification in 
  *
@@ -230,6 +230,15 @@ getadrx (const char *addrs)
            break;
        }
 
+    /*
+     * Reject the address if key fields contain 8bit characters
+     */
+
+    if (contains8bit(mbox, NULL) || contains8bit(host, NULL) ||
+       contains8bit(path, NULL) || contains8bit(grp, NULL)) {
+       strcpy(err, "Address contains 8-bit characters");
+    }
+
     if (err[0])
        for (;;) {
            switch (last_lex) {