Commit 19c943dc authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Copy IPv4 multicast TTL from RTP to RTCP.

We were sending RTCP with TTL=1 all the time...
(cherry picked from commit 7da51390)
parent dac13787
...@@ -99,6 +99,16 @@ rtcp_sender_t *OpenRTCP (vlc_object_t *obj, int rtp_fd, int proto, ...@@ -99,6 +99,16 @@ rtcp_sender_t *OpenRTCP (vlc_object_t *obj, int rtp_fd, int proto,
dport++; dport++;
fd = net_OpenDgram (obj, src, sport, dst, dport, AF_UNSPEC, proto); fd = net_OpenDgram (obj, src, sport, dst, dport, AF_UNSPEC, proto);
/* Copy the multicast IPv4 TTL value (useless for IPv6) */
if (fd != -1)
{
int ttl;
socklen_t len = sizeof (ttl);
if (!getsockopt (rtp_fd, SOL_IP, IP_MULTICAST_TTL, &ttl, &len))
setsockopt (fd, SOL_IP, IP_MULTICAST_TTL, &ttl, len);
}
} }
if (fd == -1) if (fd == -1)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment