diff --git a/include/libtorrent/packet_pool.hpp b/include/libtorrent/packet_pool.hpp index 0b23b250f..cfe96d07e 100644 --- a/include/libtorrent/packet_pool.hpp +++ b/include/libtorrent/packet_pool.hpp @@ -56,7 +56,6 @@ namespace libtorrent { constexpr int TORRENT_ETHERNET_MTU = 1500; constexpr int TORRENT_TEREDO_MTU = 1280; constexpr int TORRENT_INET_MIN_MTU = 576; - constexpr int TORRENT_INET_MAX_MTU = 0xffff; // used for out-of-order incoming packets // as well as sent packets that are waiting to be ACKed diff --git a/src/utp_socket_manager.cpp b/src/utp_socket_manager.cpp index ffb35a36e..db061961c 100644 --- a/src/utp_socket_manager.cpp +++ b/src/utp_socket_manager.cpp @@ -105,10 +105,6 @@ namespace libtorrent { } #endif - // clamp the MTU within reasonable bounds - if (mtu < TORRENT_INET_MIN_MTU) mtu = TORRENT_INET_MIN_MTU; - else if (mtu > TORRENT_INET_MAX_MTU) mtu = TORRENT_INET_MAX_MTU; - int const link_mtu = mtu; mtu -= TORRENT_UDP_HEADER;