aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonio Quartulli2023-03-20 20:58:20 +0100
committerGert Doering2023-03-21 09:21:17 +0100
commit047f772b84843344b6131e9e915472d14adcea2b (patch)
treeb1848090f18cc9404be98eed3d2bce5fcfbbfcf6
parentc20a15844829a186b4d5256b0e8d76b8eb074845 (diff)
downloadopenvpn-047f772b84843344b6131e9e915472d14adcea2b.zip
openvpn-047f772b84843344b6131e9e915472d14adcea2b.tar.gz
dco-linux: remove M_ERRNO flag when printing netlink error message
Netlink has its own error space and reports errors via the return value of its functions. For this reason remove the M_ERRNO flag when printing its errors. At the moment we get something like this: netlink reports error (-7): Invalid input data or parameter: Interrupted system call (errno=4) where the errno=4 (and its human readable representation) is a leftover from the previous recv() interrupted by a signal and it is totally unrelated to this netlink failure. Signed-off-by: Antonio Quartulli <a@unstable.cc> Acked-by: Gert Doering <gert@greenie.muc.de> Message-Id: <20230320195820.6675-1-a@unstable.cc> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg26452.html Signed-off-by: Gert Doering <gert@greenie.muc.de> (cherry picked from commit 23903fd579353c9892415a750f17a9832a79cced)
-rw-r--r--src/openvpn/dco_linux.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/openvpn/dco_linux.c b/src/openvpn/dco_linux.c
index e5cea3c..4796184 100644
--- a/src/openvpn/dco_linux.c
+++ b/src/openvpn/dco_linux.c
@@ -153,7 +153,7 @@ ovpn_nl_recvmsgs(dco_context_t *dco, const char *prefix)
default:
if (ret)
{
- msg(M_NONFATAL|M_ERRNO, "%s: netlink reports error (%d): %s", prefix, ret, nl_geterror(-ret));
+ msg(M_NONFATAL, "%s: netlink reports error (%d): %s", prefix, ret, nl_geterror(-ret));
}
break;
}