X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/4e3c586d24d33c0d0f6b1f16a84cf9b1a08076d7..b4f2851d:/uip/viamail.c?ds=inline diff --git a/uip/viamail.c b/uip/viamail.c index 37514d5a..7c81079d 100644 --- a/uip/viamail.c +++ b/uip/viamail.c @@ -11,8 +11,6 @@ #include #include #include -#include -#include #include #include #include @@ -189,6 +187,7 @@ via_mail (char *mailsw, char *subjsw, char *parmsw, char *descsw, struct stat st; FILE *fp; char *tfile = NULL; + char *cp; umask (~m_gmprot ()); @@ -245,6 +244,12 @@ via_mail (char *mailsw, char *subjsw, char *parmsw, char *descsw, if (verbsw) vec[vecp++] = "-verbose"; + if ((cp = context_find ("credentials"))) { + /* post doesn't read context so need to pass credentials. */ + vec[vecp++] = "-credentials"; + vec[vecp++] = cp; + } + switch (sendsbr (vec, vecp, program, tmpfil, &st, 0, (char *)0, 0)) { case DONE: case NOTOK: