Message-ID: <447e0a7c-a60d-1085-12d1-64c3ebc8c589@...1227...> Date: Mon, 13 Dec 2021 16:39:13 +0100 MIME-Version: 1.0 Content-Language: en-GB References: <20211207170211.3275837-1-arne@...1227...> <20211207170211.3275837-7-arne@...1227...> <1582627291.849748.1639153050584@...2642...> From: Arne Schwabe In-Reply-To: <1582627291.849748.1639153050584@...2642...> Subject: Re: [Openvpn-devel] [PATCH 06/21] Remove post_open_mtu code List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit To: Frank Lichtenheld , "openvpn-devel@lists.sourceforge.net" Am 10.12.21 um 17:17 schrieb Frank Lichtenheld: >> Arne Schwabe hat am 07.12.2021 18:01 geschrieben: >> This code is probably from a time when we could not set the MTU on >> the Windows tap6 driver. Nowadays we can set the MTU on this device, >> so this code is a noop now. > [...] >> diff --git a/src/openvpn/tun.c b/src/openvpn/tun.c >> index 75d5eaf7b..12bdd2005 100644 >> --- a/src/openvpn/tun.c >> +++ b/src/openvpn/tun.c >> @@ -6071,7 +6071,6 @@ tuntap_get_mtu(struct tuntap *tt) >> &mtu, sizeof(mtu), >> &mtu, sizeof(mtu), &len, NULL)) >> { >> - tt->post_open_mtu = (int)mtu; >> msg(D_MTU_INFO, "TAP-Windows MTU=%d", (int)mtu); >> } >> } > > This change makes no sense to me. Why would you not remove the complete tuntap_get_mtu call? If the whole point was to get the MTU, and now it will be the one we set, why even to the ioctl at all? I wanted to keep the message that is currently printed at verb 1. If we decide that the message can be removed I can remove the calling of the ioctl as well. Arne