/*
* whatnowsbr.c -- the WhatNow shell
*
- * $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.
break;
}
+ if (*(argp+1) == (char *)0) {
+ advise((char *)0, "attach command requires file argument(s).");
+ break;
+ }
+
/*
* Build a command line that causes the user's shell to list the file name
* arguments. This handles and wildcard expansion, tilde expansion, etc.
struct stat st;
#ifdef HAVE_LSTAT
- int slinked;
+ int slinked = 0;
#if 0
int oumask; /* PJS: for setting permissions on symlinks. */
#endif
# define SASLminc(a) 0
#endif /* CYRUS_SASL */
+#ifndef TLS_SUPPORT
+# define TLSminc(a) (a)
+#else /* TLS_SUPPORT */
+# define TLSminc(a) 0
+#endif /* TLS_SUPPORT */
+
static struct swit sendswitches[] = {
#define ALIASW 0
{ "alias aliasfile", 0 },
#define SASLMECHSW 37
{ "saslmech", SASLminc(-5) },
#define USERSW 38
- { "user", SASLminc(4) },
+ { "user", SASLminc(-4) },
#define SNDATTACHSW 39
{ "attach file", 6 },
#define SNDATTACHFORMAT 40
{ "attachformat", 7 },
#define PORTSW 41
{ "port server-port-name/number", 4 },
+#define TLSSW 42
+ { "tls", TLSminc(-3) },
{ NULL, 0 }
};
case SOMLSW:
case SNOOPSW:
case SASLSW:
+ case TLSSW:
vec[vecp++] = --cp;
continue;
#endif /* not lint */
&& altmsg) {
vec[vecp++] = "-dist";
- distfile = getcpy (m_scratch (altmsg, invo_name));
+ distfile = getcpy (m_mktemp2(altmsg, invo_name, NULL, NULL));
if (link (altmsg, distfile) == NOTOK)
adios (distfile, "unable to link %s to", altmsg);
} else {