Dovecot fixes from upstream via Brad.
- maildir: If uidlist isn't read, don't mark its UIDs as being known when saving. - maildir: Avoid unnecessary uidlist recreation during mail delivery. - Removed "die after 3 EINTR write() failures to log".
This commit is contained in:
parent
d425867587
commit
2fc3a32af5
@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.148 2010/09/17 13:11:14 sthen Exp $
|
||||
# $OpenBSD: Makefile,v 1.149 2010/09/17 22:00:18 sthen Exp $
|
||||
|
||||
SHARED_ONLY= Yes
|
||||
|
||||
@ -12,9 +12,9 @@ V_MANAGESIEVE= 0.11.11
|
||||
|
||||
PKGNAME= dovecot-${V_DOVECOT}
|
||||
PKGNAME-server= dovecot-${V_DOVECOT}
|
||||
REVISION-server=0
|
||||
REVISION-server=1
|
||||
FULLPKGNAME-sieve= dovecot-sieve-${V_SIEVE}
|
||||
REVISION-sieve= 2
|
||||
REVISION-sieve= 3
|
||||
EPOCH-sieve= 0
|
||||
FULLPKGPATH-sieve= ${PKGPATH},-sieve
|
||||
|
||||
@ -28,7 +28,7 @@ DISTFILES= dovecot-${V_DOVECOT}.tar.gz \
|
||||
dovecot-${V_MAJOR}-managesieve-${V_MANAGESIEVE}.tar.gz:0 \
|
||||
${DIST_MANAGESIEVE}:0
|
||||
|
||||
DIST_MANAGESIEVE= dovecot-1.2.13-managesieve-${V_MANAGESIEVE}.diff.gz
|
||||
DIST_MANAGESIEVE= dovecot-${V_DOVECOT}-managesieve-${V_MANAGESIEVE}.diff.gz
|
||||
|
||||
HOMEPAGE= http://www.dovecot.org/
|
||||
|
||||
|
@ -1,20 +1,20 @@
|
||||
MD5 (dovecot-1.2-managesieve-0.11.11.tar.gz) = MrqNR6NpX4UUvSwr9zSPlg==
|
||||
MD5 (dovecot-1.2-sieve-0.1.17.tar.gz) = uheooIOG6ycxeTt0MXAD4g==
|
||||
MD5 (dovecot-1.2.13-managesieve-0.11.11.diff.gz) = s5ArdocGHdEtoyMR0gnGaw==
|
||||
MD5 (dovecot-1.2.14-managesieve-0.11.11.diff.gz) = k9aO/1IPsEXvkMv3lmfYLA==
|
||||
MD5 (dovecot-1.2.14.tar.gz) = H+QemcHeoxG+7m1NmUSQzA==
|
||||
RMD160 (dovecot-1.2-managesieve-0.11.11.tar.gz) = Fh0UP1pCrukpq/UbYrOw5uep8Ho=
|
||||
RMD160 (dovecot-1.2-sieve-0.1.17.tar.gz) = e1N0LHOIvydSGka44RIfRadk34c=
|
||||
RMD160 (dovecot-1.2.13-managesieve-0.11.11.diff.gz) = 0m+k22bHTUb8VicD9Ek+5NWhsqc=
|
||||
RMD160 (dovecot-1.2.14-managesieve-0.11.11.diff.gz) = QWhOzTZn/qxxoyV4avvvItClEZ0=
|
||||
RMD160 (dovecot-1.2.14.tar.gz) = kWso463hZpVG4ZIRon2JcaKqv4c=
|
||||
SHA1 (dovecot-1.2-managesieve-0.11.11.tar.gz) = U/hhip4C+VORI5CnuAPrYhi/lpo=
|
||||
SHA1 (dovecot-1.2-sieve-0.1.17.tar.gz) = QgFCqEONduOElyfDq0veWlt/t+Q=
|
||||
SHA1 (dovecot-1.2.13-managesieve-0.11.11.diff.gz) = Y2sbtNvP2egsk/r05P34Pi3O51U=
|
||||
SHA1 (dovecot-1.2.14-managesieve-0.11.11.diff.gz) = g7OViYELrtxVpuFeNHN9fejsSMw=
|
||||
SHA1 (dovecot-1.2.14.tar.gz) = wdqMdWO9Ii2wPLTNW7Jr1PnWtFs=
|
||||
SHA256 (dovecot-1.2-managesieve-0.11.11.tar.gz) = eSzAbmAlDin1F6+jUAaa8tcAF0ZEXTsZu/Gu+LbdhT4=
|
||||
SHA256 (dovecot-1.2-sieve-0.1.17.tar.gz) = 4CpKG1lYu+HI4hbxHQAWbjPDGzBMvUGA3imxod1efQs=
|
||||
SHA256 (dovecot-1.2.13-managesieve-0.11.11.diff.gz) = hkb834wP2mn4sN+I2TVoYeEk1/cMdd8a+3FHac2E6e0=
|
||||
SHA256 (dovecot-1.2.14-managesieve-0.11.11.diff.gz) = W/GoyYP3jCtJ2QaLtX9SABEm/NHnqxxdr586VYwI5pY=
|
||||
SHA256 (dovecot-1.2.14.tar.gz) = klzV0eil5evW4rmIeVerH5HUb/jWRmC6jtQ1Q6QNa54=
|
||||
SIZE (dovecot-1.2-managesieve-0.11.11.tar.gz) = 439239
|
||||
SIZE (dovecot-1.2-sieve-0.1.17.tar.gz) = 1029070
|
||||
SIZE (dovecot-1.2.13-managesieve-0.11.11.diff.gz) = 6463
|
||||
SIZE (dovecot-1.2.14-managesieve-0.11.11.diff.gz) = 6459
|
||||
SIZE (dovecot-1.2.14.tar.gz) = 2947472
|
||||
|
@ -0,0 +1,46 @@
|
||||
$OpenBSD: patch-src_lib-storage_index_maildir_maildir-uidlist_c,v 1.3 2010/09/17 22:00:18 sthen Exp $
|
||||
--- src/lib-storage/index/maildir/maildir-uidlist.c.orig Fri Sep 17 09:44:44 2010
|
||||
+++ src/lib-storage/index/maildir/maildir-uidlist.c Fri Sep 17 09:48:18 2010
|
||||
@@ -89,6 +89,7 @@ struct maildir_uidlist {
|
||||
string_t *hdr_extensions;
|
||||
|
||||
unsigned int recreate:1;
|
||||
+ unsigned int recreate_on_change:1;
|
||||
unsigned int initial_read:1;
|
||||
unsigned int initial_hdr_read:1;
|
||||
unsigned int retry_rewind:1;
|
||||
@@ -758,7 +759,7 @@ maildir_uidlist_update_read(struct maildir_uidlist *ui
|
||||
ret = -1;
|
||||
|
||||
if (uidlist->unsorted) {
|
||||
- uidlist->recreate = TRUE;
|
||||
+ uidlist->recreate_on_change = TRUE;
|
||||
maildir_uidlist_records_sort_by_uid(uidlist);
|
||||
}
|
||||
if (uidlist->next_uid <= uidlist->prev_read_uid)
|
||||
@@ -1375,6 +1376,7 @@ static int maildir_uidlist_recreate(struct maildir_uid
|
||||
uidlist->fd_size = st.st_size;
|
||||
uidlist->last_read_offset = st.st_size;
|
||||
uidlist->recreate = FALSE;
|
||||
+ uidlist->recreate_on_change = FALSE;
|
||||
maildir_uidlist_update_hdr(uidlist, &st);
|
||||
}
|
||||
if (ret < 0)
|
||||
@@ -1446,7 +1448,7 @@ static int maildir_uidlist_sync_update(struct maildir_
|
||||
}
|
||||
|
||||
|
||||
- if (maildir_uidlist_want_recreate(ctx))
|
||||
+ if (maildir_uidlist_want_recreate(ctx) || uidlist->recreate_on_change)
|
||||
return maildir_uidlist_recreate(uidlist);
|
||||
|
||||
if (!uidlist->locked_refresh || uidlist->fd == -1) {
|
||||
@@ -1796,7 +1798,7 @@ static void maildir_uidlist_assign_uids(struct maildir
|
||||
recs[dest]->flags &= ~MAILDIR_UIDLIST_REC_FLAG_MOVED;
|
||||
}
|
||||
|
||||
- if (ctx->uidlist->locked_refresh)
|
||||
+ if (ctx->uidlist->locked_refresh && ctx->uidlist->initial_read)
|
||||
ctx->uidlist->last_seen_uid = ctx->uidlist->next_uid-1;
|
||||
|
||||
ctx->new_files_count = 0;
|
23
mail/dovecot/patches/patch-src_lib_failures_c
Normal file
23
mail/dovecot/patches/patch-src_lib_failures_c
Normal file
@ -0,0 +1,23 @@
|
||||
$OpenBSD: patch-src_lib_failures_c,v 1.3 2010/09/17 22:00:18 sthen Exp $
|
||||
--- src/lib/failures.c.orig Fri Sep 17 09:48:50 2010
|
||||
+++ src/lib/failures.c Fri Sep 17 09:50:37 2010
|
||||
@@ -81,7 +81,6 @@ static int log_fd_write(int fd, const unsigned char *d
|
||||
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) {
|
||||
@@ -95,9 +94,9 @@ static int log_fd_write(int fd, const unsigned char *d
|
||||
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)
|
Loading…
Reference in New Issue
Block a user