From bb773720e9cfd78bdba7190867fd221b767b90da Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Wed, 9 Feb 2022 09:10:44 +0100 Subject: tracker/udp: use SO_REUSEADDR Issue: #1424 --- tracker-udp/ftnoir_tracker_udp.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tracker-udp/ftnoir_tracker_udp.cpp') diff --git a/tracker-udp/ftnoir_tracker_udp.cpp b/tracker-udp/ftnoir_tracker_udp.cpp index 6badaa0f..f1f9f033 100644 --- a/tracker-udp/ftnoir_tracker_udp.cpp +++ b/tracker-udp/ftnoir_tracker_udp.cpp @@ -70,7 +70,7 @@ void udp::run() module_status udp::start_tracker(QFrame*) { - if (!sock.bind(QHostAddress::Any, quint16(s.port), QUdpSocket::DontShareAddress)) + if (!sock.bind(QHostAddress::Any, quint16(s.port), QUdpSocket::ShareAddress | QUdpSocket::ReuseAddressHint)) return error(tr("Can't bind socket -- %1").arg(sock.errorString())); sock.moveToThread(this); -- cgit v1.2.3