]> diplodocus.org Git - nmh/blobdiff - test/mhmail/test-mhmail
Change test-mhmail so it can handle a MIMETYPEPROC that doesn't output
[nmh] / test / mhmail / test-mhmail
index c773c04180637dddb0fd0182654a897ac070013b..27188c77f42aa7f832fa619d7ec154ef4ec3a343 100755 (executable)
@@ -22,9 +22,8 @@ content_type_string() {
   else
     # 1) Excise leading filename followed by : and any whitespace.
     # 2) Wrap charset value in double quotes.  Assume that it isn't already.
   else
     # 1) Excise leading filename followed by : and any whitespace.
     # 2) Wrap charset value in double quotes.  Assume that it isn't already.
-    printf "%s %s%s" \
-      `$MIMETYPEPROC $1 | sed -e 's/.*: *//' -e 's/\(charset=\)\(.*\)/\1"\2"/'`\
-      "; name=\"`basename $1`\""
+    printf "%s%s" \
+      `$MIMETYPEPROC $1` "; name=\"`basename $1`\"; charset=\"us-ascii\""
   fi
 }
 
   fi
 }