diff --git a/libtransmission/tr-lpd.cc b/libtransmission/tr-lpd.cc index 95705e1fc..97c66a6a3 100644 --- a/libtransmission/tr-lpd.cc +++ b/libtransmission/tr-lpd.cc @@ -394,6 +394,13 @@ private: { return false; } + + // needed to announce to BT clients on the same interface + if (setsockopt(sock, IPPROTO_IP, IP_MULTICAST_LOOP, reinterpret_cast(&opt_on), sizeof(opt_on)) == + -1) + { + return false; + } } else // TR_AF_INET6 { @@ -434,6 +441,17 @@ private: { return false; } + + // needed to announce to BT clients on the same interface + if (setsockopt( + sock, + IPPROTO_IPV6, + IPV6_MULTICAST_LOOP, + reinterpret_cast(&opt_on), + sizeof(opt_on)) == -1) + { + return false; + } } }