#include <h/fmt_scan.h>
#include <h/tws.h>
#include <h/utils.h>
-#include <h/m_setjmp.h>
+#include <setjmp.h>
#include <signal.h>
#include <errno.h>
#include <sys/wait.h>
{ NULL, 0, 0 }
};
+static char *addrcomps[] = {
+ "from",
+ "sender",
+ "reply-to",
+ "to",
+ "cc",
+ "bcc",
+ "resent-from",
+ "resent-sender",
+ "resent-reply-to",
+ "resent-to",
+ "resent-cc",
+ "resent-bcc",
+ NULL
+};
+
static int bellflg = 0;
static int clearflg = 0;
mhl (int argc, char **argv)
{
int length = 0, nomore = 0;
- unsigned int i, vecp = 0;;
+ unsigned int i, vecp = 0;
int width = 0;
char *cp, *folder = NULL, *form = NULL;
char buf[BUFSIZ], *files[MAXARGS];
struct mcomp *c1;
struct stat st;
- switch (m_setjmp (env)) {
+ switch (setjmp (env)) {
case OK:
if (fname) {
fp = mhl_action ? (*mhl_action) (fname) : fopen (fname, "r");
char *cp = NULL;
struct mcomp *c1;
- switch (m_setjmp (mhlenv)) {
+ switch (setjmp (mhlenv)) {
case OK:
cp = invo_name;
sleepsw = 0; /* XXX */
{
struct format *fmt;
struct arglist *args;
+ char **ap;
+ struct comp *cptr;
unsigned int i;
i = fmt_compile(nfs, &fmt);
+ /*
+ * Search through and mark any components that are address components
+ */
+
+ for (ap = addrcomps; *ap; ap++) {
+ FINDCOMP (cptr, *ap);
+ if (cptr)
+ cptr->c_type |= CT_ADDR;
+ }
+
args = (struct arglist *) mh_xmalloc(sizeof(struct arglist));
if (! args)
if (mh_strcasecmp(name, c->c_name) == 0) {
found++;
if (! c->c_text) {
- i = strlen(c->c_text = strdup(buf)) - 1;
- if (c->c_text[i] == '\n')
- c->c_text[i] = '\0';
+ c->c_text = strdup(buf);
} else {
i = strlen(cp = c->c_text) - 1;
if (cp[i] == '\n') {