summaryrefslogtreecommitdiff
path: root/net-mail/dovecot/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-07-19 22:05:27 +0100
committerV3n3RiX <venerix@redcorelinux.org>2019-07-19 22:05:27 +0100
commit121ed4eec41fbf03e1998d09eede1bf449da63b9 (patch)
treece9341d77d1507f67d4a3a1472da9011b5baa0a8 /net-mail/dovecot/files
parentdd762ff83c330186ee2ede002e08b2f780cddd51 (diff)
gentoo resync : 19.07.2019
Diffstat (limited to 'net-mail/dovecot/files')
-rw-r--r--net-mail/dovecot/files/dovecot-no-log-error-tcp_nodelay.patch31
-rw-r--r--[-rwxr-xr-x]net-mail/dovecot/files/dovecot.init-r62
2 files changed, 32 insertions, 1 deletions
diff --git a/net-mail/dovecot/files/dovecot-no-log-error-tcp_nodelay.patch b/net-mail/dovecot/files/dovecot-no-log-error-tcp_nodelay.patch
new file mode 100644
index 000000000000..3a2acd74fb65
--- /dev/null
+++ b/net-mail/dovecot/files/dovecot-no-log-error-tcp_nodelay.patch
@@ -0,0 +1,31 @@
+diff --git a/src/lib/ostream-file.c b/src/lib/ostream-file.c
+index e7e6f62d12..82bf729ac0 100644
+--- a/src/lib/ostream-file.c
++++ b/src/lib/ostream-file.c
+@@ -333,17 +333,17 @@ static int buffer_flush(struct file_ostream *fstream)
+ static void o_stream_tcp_flush_via_nodelay(struct file_ostream *fstream)
+ {
+ if (net_set_tcp_nodelay(fstream->fd, TRUE) < 0) {
+- if (errno != ENOTSUP && errno != ENOTSOCK &&
+- errno != ENOPROTOOPT) {
+- i_error("file_ostream.net_set_tcp_nodelay(%s, TRUE) failed: %m",
+- o_stream_get_name(&fstream->ostream.ostream));
+- }
++ /* Don't bother logging errors. There are quite a lot of
++ different errors that need to be ignored, and it differs
++ between OSes. At least:
++ Linux: ENOTSUP, ENOTSOCK, ENOPROTOOPT
++ FreeBSD: EINVAL, ECONNRESET */
+ fstream->no_socket_nodelay = TRUE;
+ } else if (net_set_tcp_nodelay(fstream->fd, FALSE) < 0) {
+- /* We already successfully enabled TCP_NODELAY, so we're really
+- not expecting any errors here. */
+- i_error("file_ostream.net_set_tcp_nodelay(%s, FALSE) failed: %m",
+- o_stream_get_name(&fstream->ostream.ostream));
++ /* We already successfully enabled TCP_NODELAY, so there
++ shouldn't really be errors. Except ECONNRESET can possibly
++ still happen between these two calls, so again don't log
++ errors. */
+ fstream->no_socket_nodelay = TRUE;
+ }
+ }
diff --git a/net-mail/dovecot/files/dovecot.init-r6 b/net-mail/dovecot/files/dovecot.init-r6
index ad096bff7502..cff64bee4995 100755..100644
--- a/net-mail/dovecot/files/dovecot.init-r6
+++ b/net-mail/dovecot/files/dovecot.init-r6
@@ -1,5 +1,5 @@
#!/sbin/openrc-run
-# Copyright 1999-2018 Gentoo Authors
+# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License, v2 or later
extra_commands="checkconfig"