dovecot-1.1: Removed "die after 3 EINTR write() failures to log".
dovecot at dovecot.org
dovecot at dovecot.org
Wed Sep 15 20:43:26 EEST 2010
details: http://hg.dovecot.org/dovecot-1.1/rev/27a0fd89e181
changeset: 8369:27a0fd89e181
user: Timo Sirainen <tss at iki.fi>
date: Wed Sep 15 18:42:58 2010 +0100
description:
Removed "die after 3 EINTR write() failures to log".
This can happen with a busy master process that is receiving a lot of
SIGCHLD signals rapidly while trying to log.
diffstat:
src/lib/failures.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diffs (23 lines):
diff -r 3fdeac838172 -r 27a0fd89e181 src/lib/failures.c
--- a/src/lib/failures.c Wed Aug 18 15:17:40 2010 +0100
+++ b/src/lib/failures.c Wed Sep 15 18:42:58 2010 +0100
@@ -82,7 +82,6 @@
struct ioloop *ioloop;
struct io *io;
ssize_t ret;
- unsigned int eintr_count = 0;
while ((ret = write(fd, data, len)) != (ssize_t)len) {
if (ret > 0) {
@@ -96,9 +95,9 @@
errno = ENOSPC;
return -1;
}
- if (errno == EINTR && ++eintr_count < 3) {
+ if (errno == EINTR) {
/* we don't want to die because of this.
- try again a couple of times. */
+ especially SIGCHLD signals can be coming rapidly. */
continue;
}
if (errno != EAGAIN)
More information about the dovecot-cvs
mailing list