Mail-QmailRemoteXS
view release on metacpan or search on metacpan
qmailrem/CHANGES view on Meta::CPAN
19960525 change: added qmail-popup. tnx RN.
19960525 change: added elm filter section to FAQ. tnx GB.
19960502 portability problem: on many systems, select() on an
almost-full pipe incorrectly says writable. tnx ME for running
into this and helping track it down. impact: if qmail-send
writes a pipeful to qmail-lspawn or qmail-rspawn before they
can react (because of high concurrency, high load, or long
addresses), it will receive an incorrect -1/EAGAIN, and will
conclude that spawn died. sysadmin will have to restart qmail,
and messages will be duplicated. fix: in qmail-send.c,
busy-loop if write() to spawn returns any error other than
EPIPE.
19960501 bug: qmail-alias treated NAMETOOLONG and NOTDIR as temporary
errors. impact: qmail-alias never looked for -default; even if
mail was destined to bounce, it would have to time out first.
fix: qmail-alias now uses error_temp().
19960430 bug: qmail-smtpd treated qq crash as permanent error. impact:
if somebody actively kills qq, mail will be incorrectly
bounced. tnx SS. fix: qmail-smtpd now treats only TOOLONG and
EXECHARD as permanent errors.
19960430 cleanup: eliminated QQT_TTY from qqtalk.h.
qmailrem/error_str.c view on Meta::CPAN
#define X(e,s) if (i == e) return s;
char *error_str(i)
int i;
{
X(0,"no error")
X(error_intr,"interrupted system call")
X(error_nomem,"out of memory")
X(error_noent,"file does not exist")
X(error_txtbsy,"text busy")
X(error_io,"input/output error")
X(error_exist,"file already exists")
X(error_timeout,"timed out")
X(error_inprogress,"operation in progress")
X(error_again,"temporary failure")
X(error_wouldblock,"input/output would block")
X(error_pipe,"broken pipe")
X(error_perm,"permission denied")
X(error_acces,"access denied")
#ifdef ESRCH
qmailrem/error_str.c view on Meta::CPAN
#ifdef EDEADLK
X(EDEADLK,"operation would cause deadlock")
#endif
#ifdef EFAULT
X(EFAULT,"bad address")
#endif
#ifdef ENOTBLK
X(ENOTBLK,"not a block device")
#endif
#ifdef EBUSY
X(EBUSY,"device busy")
#endif
#ifdef EXDEV
X(EXDEV,"cross-device link")
#endif
#ifdef ENODEV
X(ENODEV,"device does not support operation")
#endif
#ifdef ENOTDIR
X(ENOTDIR,"not a directory")
#endif
qmailrem/qmail-send.c view on Meta::CPAN
#include "trigger.h"
#include "newfield.h"
#include "quote.h"
#include "qmail.h"
#include "qsutil.h"
#include "prioq.h"
#include "constmap.h"
#include "fmtqfn.h"
#include "readsubdir.h"
/* critical timing feature #1: if not triggered, do not busy-loop */
/* critical timing feature #2: if triggered, respond within fixed time */
/* important timing feature: when triggered, respond instantly */
#define SLEEP_TODO 1500 /* check todo/ every 25 minutes in any case */
#define SLEEP_FUZZ 1 /* slop a bit on sleeps to avoid zeno effect */
#define SLEEP_FOREVER 86400 /* absolute maximum time spent in select() */
#define SLEEP_CLEANUP 76431 /* time between cleanups */
#define SLEEP_SYSFAIL 123
#define OSSIFIED 129600 /* 36 hours; _must_ exceed q-q's DEATH (24 hours) */
int lifetime = 604800;
qmailrem/qmail-send.c view on Meta::CPAN
{
int w;
int len;
len = comm_buf[c].len;
w = write(chanfdout[c],comm_buf[c].s + comm_pos[c],len - comm_pos[c]);
if (w <= 0)
{
if ((w == -1) && (errno == error_pipe))
spawndied(c);
else
continue; /* kernel select() bug; can't avoid busy-looping */
}
else
{
comm_pos[c] += w;
if (comm_pos[c] == len)
comm_buf[c].len = 0;
}
}
}
( run in 0.453 second using v1.01-cache-2.11-cpan-87723dcf8b7 )