]> git.ipfire.org Git - thirdparty/openvpn.git/commitdiff
close_tun: print interface type consistently in message
authorAntonio Quartulli <a@unstable.cc>
Sat, 22 Oct 2022 20:55:21 +0000 (22:55 +0200)
committerGert Doering <gert@greenie.muc.de>
Sun, 23 Oct 2022 16:08:51 +0000 (18:08 +0200)
When closing the tunnel interface we know if we were using DCO or not.
for this reason we can customize the closing message and make it
consistent with the opening one.

Signed-off-by: Antonio Quartulli <a@unstable.cc>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20221022205521.29406-1-a@unstable.cc>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg25449.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/init.c

index c48048a1bd18ee73eec82fafd3a51cd72eb4ef9a..fe554ffd577a2835f9a1ecbc15e90d2bf8cea1d8 100644 (file)
@@ -1946,7 +1946,9 @@ do_open_tun(struct context *c)
 static void
 do_close_tun_simple(struct context *c)
 {
-    msg(D_CLOSE, "Closing TUN/TAP interface");
+    msg(D_CLOSE, "Closing %s interface",
+        dco_enabled(&c->options) ? "DCO" : "TUN/TAP");
+
     if (c->c1.tuntap)
     {
         if (!c->options.ifconfig_noexec)