🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.mail.sendmail
Article #2536

non-local mail fails if resources are unavailable

#2536
From: Eric Wassenaar
Date: Sat, 15 Jun 1991 14:57
33 lines
1641 bytes
The syserr() call after the execve() in openmailer() in deliver.c
clears errno which is checked afterwards to determine the proper
exit status.
This causes delivery via non-LocalMailers to fail instead of
being requeued in case of temporary lack of o.s. resources.

openmailer()
{
		execve(m->m_mailer, pvp, UserEnviron);
		syserr("Cannot exec %s", m->m_mailer);
                if (m == LocalMailer || errno == EIO || errno == EAGAIN ||
#if defined(EPROCLIM)
							errno == EPROCLIM ||
#endif /* EPROCLIM */
                    errno == ENOMEM)
			_exit(EX_TEMPFAIL);
		else
			_exit(EX_UNAVAILABLE);

errno should be saved just after the execve() call in a separate
variable to be checked after the syserr() call.

By the way, I think EX_OSERR is a more appropriate status than
EX_TEMPFAIL. It will cause a more descriptive message than the
plain "Deferred" you use to see in these cases.

Eric Wassenaar
-- 
Organization: NIKHEF-H, National Institute for Nuclear and High-Energy Physics
Address: Kruislaan 409, P.O. Box 41882, 1009 DB Amsterdam, the Netherlands
Phone: +31 20 592 0412, Home: +31 20 6909449, Telefax: +31 20 592 5155
Internet: e07@nikhef.nl
Technical Details
Message-ID: <1253@nikhefh.nikhef.nl>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!mips!spool.mu.edu!olivea!uunet!mcsun!hp4nl!nikhefh!e07

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!mips!spool.mu.edu!olivea!uunet!mcsun!hp4nl!nikhefh!e07
From: e07@nikhefh.nikhef.nl (Eric Wassenaar)
Newsgroups: comp.mail.sendmail
Subject: non-local mail fails if resources are unavailable
Message-ID: <1253@nikhefh.nikhef.nl>
Date: 15 Jun 91 14:57:16 GMT
Sender: e07@nikhef.nl (Eric Wassenaar)
Organization: Nikhef-H, Amsterdam (the Netherlands).
Lines: 33