projects
/
mmh
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Cleaned up uip/mhmail. Added chmod +x of spost in configure.ac.
[mmh]
/
uip
/
mhbuild.c
diff --git
a/uip/mhbuild.c
b/uip/mhbuild.c
index
ad674f4
..
e8e7423
100644
(file)
--- a/
uip/mhbuild.c
+++ b/
uip/mhbuild.c
@@
-25,43
+25,47
@@
static struct swit switches[] = {
{ "check", 0 },
#define NCHECKSW 1
{ "nocheck", 0 },
{ "check", 0 },
#define NCHECKSW 1
{ "nocheck", 0 },
-#define EBCDICSW 2
+#define DIRECTIVES 2
+ { "directives", 0 },
+#define NDIRECTIVES 3
+ { "nodirectives", 0 },
+#define EBCDICSW 4
{ "ebcdicsafe", 0 },
{ "ebcdicsafe", 0 },
-#define NEBCDICSW 3
+#define NEBCDICSW 5
{ "noebcdicsafe", 0 },
{ "noebcdicsafe", 0 },
-#define HEADSW 4
+#define HEADSW 6
{ "headers", 0 },
{ "headers", 0 },
-#define NHEADSW 5
+#define NHEADSW 7
{ "noheaders", 0 },
{ "noheaders", 0 },
-#define LISTSW 6
+#define LISTSW 8
{ "list", 0 },
{ "list", 0 },
-#define NLISTSW 7
+#define NLISTSW 9
{ "nolist", 0 },
{ "nolist", 0 },
-#define SIZESW 8
+#define SIZESW 10
{ "realsize", 0 },
{ "realsize", 0 },
-#define NSIZESW 9
+#define NSIZESW 11
{ "norealsize", 0 },
{ "norealsize", 0 },
-#define RFC934SW 10
+#define RFC934SW 12
{ "rfc934mode", 0 },
{ "rfc934mode", 0 },
-#define NRFC934SW 11
+#define NRFC934SW 13
{ "norfc934mode", 0 },
{ "norfc934mode", 0 },
-#define VERBSW 12
+#define VERBSW 14
{ "verbose", 0 },
{ "verbose", 0 },
-#define NVERBSW 13
+#define NVERBSW 15
{ "noverbose", 0 },
{ "noverbose", 0 },
-#define RCACHESW 14
+#define RCACHESW 16
{ "rcache policy", 0 },
{ "rcache policy", 0 },
-#define WCACHESW 15
+#define WCACHESW 17
{ "wcache policy", 0 },
{ "wcache policy", 0 },
-#define CONTENTIDSW 16
+#define CONTENTIDSW 18
{ "contentid", 0 },
{ "contentid", 0 },
-#define NCONTENTIDSW 17
+#define NCONTENTIDSW 19
{ "nocontentid", 0 },
{ "nocontentid", 0 },
-#define VERSIONSW 18
+#define VERSIONSW 20
{ "version", 0 },
{ "version", 0 },
-#define HELPSW 19
+#define HELPSW 21
{ "help", 0 },
{ "help", 0 },
-#define DEBUGSW 20
+#define DEBUGSW 22
{ "debug", -5 },
{ NULL, 0 }
};
{ "debug", -5 },
{ NULL, 0 }
};
@@
-96,7
+100,7
@@
static int unlink_outfile = 0;
static void unlink_done (int) NORETURN;
/* mhbuildsbr.c */
static void unlink_done (int) NORETURN;
/* mhbuildsbr.c */
-CT build_mime (char *);
+CT build_mime (char *, int);
int output_message (CT, char *);
int output_message_fp (CT, FILE *, char*);
int output_message (CT, char *);
int output_message_fp (CT, FILE *, char*);
@@
-110,7
+114,7
@@
void free_content (CT);
int
main (int argc, char **argv)
{
int
main (int argc, char **argv)
{
- int sizesw = 1, headsw = 1;
+ int sizesw = 1, headsw = 1, directives = 1;
int *icachesw;
char *cp, buf[BUFSIZ];
char buffer[BUFSIZ], *compfile = NULL;
int *icachesw;
char *cp, buf[BUFSIZ];
char buffer[BUFSIZ], *compfile = NULL;
@@
-153,10
+157,10
@@
main (int argc, char **argv)
case HELPSW:
snprintf (buf, sizeof(buf), "%s [switches] file", invo_name);
print_help (buf, switches, 1);
case HELPSW:
snprintf (buf, sizeof(buf), "%s [switches] file", invo_name);
print_help (buf, switches, 1);
- done (1);
+ done (0);
case VERSIONSW:
print_version(invo_name);
case VERSIONSW:
print_version(invo_name);
- done (1);
+ done (0);
case RCACHESW:
icachesw = &rcachesw;
case RCACHESW:
icachesw = &rcachesw;
@@
-198,6
+202,13
@@
main (int argc, char **argv)
headsw = 0;
continue;
headsw = 0;
continue;
+ case DIRECTIVES:
+ directives = 1;
+ continue;
+ case NDIRECTIVES:
+ directives = 0;
+ continue;
+
case LISTSW:
listsw++;
continue;
case LISTSW:
listsw++;
continue;
@@
-243,11
+254,6
@@
main (int argc, char **argv)
compfile = cp;
}
compfile = cp;
}
- set_endian ();
-
- if ((cp = getenv ("MM_NOASK")) && !strcmp (cp, "1"))
- listsw = 0;
-
/*
* Check if we've specified an additional profile
*/
/*
* Check if we've specified an additional profile
*/
@@
-306,7
+312,7
@@
main (int argc, char **argv)
unlink_infile = 1;
/* build the content structures for MIME message */
unlink_infile = 1;
/* build the content structures for MIME message */
- ct = build_mime (infile);
+ ct = build_mime (infile, directives);
cts[0] = ct;
cts[1] = NULL;
cts[0] = ct;
cts[1] = NULL;
@@
-340,7
+346,7
@@
main (int argc, char **argv)
*/
/* build the content structures for MIME message */
*/
/* build the content structures for MIME message */
- ct = build_mime (compfile);
+ ct = build_mime (compfile, directives);
cts[0] = ct;
cts[1] = NULL;
cts[0] = ct;
cts[1] = NULL;