ports@, Brad,
Here a backport of small fix for OpenBSD from mine PR to fix 2.4 branch on
OpenBSD: https://github.com/dovecot/core/pull/224
Right now I can find in logs a errors like:
Fatal: connect(...) failed: Address already in use
not often, like a few times per week.
With this fix which extend FreeBSD's condition to OpenBSD as well, such
errors dissapears.
The diff:
Index: Makefile
===================================================================
RCS file: /cvs/ports/mail/dovecot/Makefile,v
retrieving revision 1.319
diff -u -p -r1.319 Makefile
--- Makefile 5 Oct 2024 07:35:54 -0000 1.319
+++ Makefile 13 Oct 2024 09:26:24 -0000
@@ -11,7 +11,7 @@ COMMENT-postgresql= PostgreSQL authentic
V_MAJOR= 2.3
V_DOVECOT= 2.3.21.1
EPOCH= 0
-REVISION= 0
+REVISION= 1
DISTNAME= dovecot-${V_DOVECOT}
PKGNAME= dovecot-${V_DOVECOT}
Index: patches/patch-src_lib_net_c
===================================================================
RCS file: patches/patch-src_lib_net_c
diff -N patches/patch-src_lib_net_c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-src_lib_net_c 13 Oct 2024 09:26:24 -0000
@@ -0,0 +1,12 @@
+Index: src/lib/net.c
+--- src/lib/net.c.orig
++++ src/lib/net.c
+@@ -213,7 +213,7 @@ static int net_connect_ip_full(const struct ip_addr *i
+ fd = net_connect_ip_once(ip, port, my_ip, sock_type, blocking);
+ if (fd != -1 || try++ >= MAX_CONNECT_RETRIES ||
+ (errno != EADDRNOTAVAIL
+-#ifdef __FreeBSD__
++#if defined(__FreeBSD__) || defined(__OpenBSD__)
+ /* busy */
+ && errno != EADDRINUSE
+ /* pf may cause this if another connection used
--
wbr, Kirill
No comments:
Post a Comment