summaryrefslogtreecommitdiffstats
path: root/contrib/sendmail/src/envelope.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/sendmail/src/envelope.c')
-rw-r--r--contrib/sendmail/src/envelope.c18
1 files changed, 14 insertions, 4 deletions
diff --git a/contrib/sendmail/src/envelope.c b/contrib/sendmail/src/envelope.c
index 641c621a..022c3ca 100644
--- a/contrib/sendmail/src/envelope.c
+++ b/contrib/sendmail/src/envelope.c
@@ -13,7 +13,7 @@
#include <sendmail.h>
-SM_RCSID("@(#)$Id: envelope.c,v 8.305 2008/03/31 16:32:13 ca Exp $")
+SM_RCSID("@(#)$Id: envelope.c,v 8.310 2009/12/18 17:08:01 ca Exp $")
/*
** CLRSESSENVELOPE -- clear session oriented data in an envelope
@@ -163,14 +163,14 @@ newenvelope(e, parent, rpool)
** split -- if true, split by recipient if message is queued up
**
** Returns:
-** none.
+** EX_* status (currently: 0: success, EX_IOERR on panic)
**
** Side Effects:
** housekeeping necessary to dispose of an envelope.
** Unlocks this queue file.
*/
-void
+int
dropenvelope(e, fulldrop, split)
register ENVELOPE *e;
bool fulldrop;
@@ -209,12 +209,15 @@ dropenvelope(e, fulldrop, split)
/* we must have an id to remove disk files */
if (id == NULL)
- return;
+ return EX_OK;
/* if verify-only mode, we can skip most of this */
if (OpMode == MD_VERIFY)
goto simpledrop;
+ if (tTd(92, 2))
+ sm_dprintf("dropenvelope: e_id=%s, EF_LOGSENDER=%d, LogLevel=%d\n",
+ e->e_id, bitset(EF_LOGSENDER, e->e_flags), LogLevel);
if (LogLevel > 4 && bitset(EF_LOGSENDER, e->e_flags))
logsender(e, NULL);
e->e_flags &= ~EF_LOGSENDER;
@@ -618,7 +621,11 @@ simpledrop:
}
e->e_id = NULL;
e->e_flags &= ~EF_HAS_DF;
+ if (panic)
+ return EX_IOERR;
+ return EX_OK;
}
+
/*
** CLEARENVELOPE -- clear an envelope without unlocking
**
@@ -714,6 +721,9 @@ clearenvelope(e, fullclear, rpool)
bh = bh->h_link;
nhp = &(*nhp)->h_link;
}
+#if _FFR_MILTER_ENHSC
+ e->e_enhsc[0] = '\0';
+#endif /* _FFR_MILTER_ENHSC */
}
/*
** INITSYS -- initialize instantiation of system
OpenPOWER on IntegriCloud