/*
* mhparse.c -- routines to parse the contents of MIME messages
*
- * $Id$
- *
* This code is Copyright (c) 2002, by the authors of nmh. See the
* COPYRIGHT file in the root directory of the nmh distribution for
* complete copyright information.
#include <h/mhparse.h>
#include <h/utils.h>
-#ifdef HAVE_SYS_WAIT_H
-# include <sys/wait.h>
-#endif
-
extern int debugsw;
if ((ftp = context_find (nmhaccessftp)) && !*ftp)
ftp = NULL;
-#ifndef BUILTIN_FTP
if (!ftp)
return NOTOK;
-#endif
switch (openExternal (e->eb_parent, e->eb_content, ce, file, &fd)) {
case NOTOK:
return NOTOK;
}
-#ifdef BUILTIN_FTP
- if (ftp)
-#endif
{
int child_id, i, vecp;
char *vec[9];
default:
if (pidXwait (child_id, NULL)) {
-#ifdef BUILTIN_FTP
-losing_ftp:
-#endif
username = password = NULL;
ce->ce_unlink = 1;
return NOTOK;
break;
}
}
-#ifdef BUILTIN_FTP
- else
- if (ftp_get (e->eb_site, user, pass, e->eb_dir, e->eb_name,
- ce->ce_file,
- e->eb_mode && !mh_strcasecmp (e->eb_mode, "ascii"), 0)
- == NOTOK)
- goto losing_ftp;
-#endif
if (cachefile[0]) {
if (caching)