]> git.ipfire.org Git - thirdparty/openvpn.git/commit
rework all occurrences of 'M_ERR | M_ERRNO'
authorGert Doering <gert@greenie.muc.de>
Wed, 11 Feb 2026 15:06:48 +0000 (16:06 +0100)
committerGert Doering <gert@greenie.muc.de>
Mon, 16 Feb 2026 14:52:26 +0000 (15:52 +0100)
commitf349b0a61499d3d36e69e2aa4dbbb7692b7d1df8
tree82f881d2f220bfefaa922b7765aec4512daa790f
parent344f13fcdfc159277e7ba7d28e23537d718e7cef
rework all occurrences of 'M_ERR | M_ERRNO'

M_ERR is defined as (M_FATAL | M_ERRNO), so 'msg(M_ERR | M_ERRNO, ...)'
is just the same as 'msg(M_ERR, ...)'.

The occurances in tun.c and dco_freebsd.c are really "if this happens,
we can not go on" errors, so 'M_ERR' (= FATAL, plus log errno string)
is the correct thing to do.

The occurances in dns.c do come with error handling and cleanup after
the msg() call, so the right thing is 'M_WARN | M_ERRNO' instead
(warning, plus log errno string).

Github: fixes OpenVPN/openvpn#939

Change-Id: I14395665f197349e374a81b56f28536ff88937a8
Signed-off-by: Gert Doering <gert@greenie.muc.de>
Acked-by: Arne Schwabe <arne-openvpn@rfc2549.org>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1517
Message-Id: <20260211150648.113547-1-frank@lichtenheld.com>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg35594.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/dco_freebsd.c
src/openvpn/dns.c
src/openvpn/tun.c