[streaming] Re: multicast ttl ??
Richard Ham
rich-lists at edit-co.com
Thu Sep 11 09:34:14 CEST 2003
----- Original Message -----
From: "Richard Ham" <rich-lists at edit-co.com>
To: <streaming at videolan.org>
Sent: Thursday, September 11, 2003 2:22 PM
Subject: [streaming] multicast ttl ??
> Hello all.....
>
> Guess this comes down to killing one prob at a time ... ;)
>
> Using a copy of vls from cvs (mid aug...... every new one I try to
d/l
> doesn't have "configure"...) and trying to change the ttl so that I
> can get through two hops of routers....
>
> Config includes:
>
> BEGIN "multicast1" # multicast example
> streamtype = "multicast"
> DstHost = "239.255.10.13" # multicast address
> DstPort = "1234" # destination port
> TTL = "5" # Time To Live
> END
>
> but no matter what, I get this outa the machine when I look at the
> stream using tcpdump :
>
> 14:06:55.207874 10.10.10.252.1037 > 239.255.10.13.1234: udp 1316
(DF)
> [ttl 1]
>
> I've hammered away at this for a bit now, and can't figure it
> out........ any clues??? Is this something Linux does (Debian 3.0r1,
> running kernel 2.4.22) or is this VLS??
>
> Regards,
>
> Richard
Hello,
I hate following up my own emails, but.....
I have tracked this down to a section of
src/modules/netchannel/netoutput.cpp (around line 168) where the
following code is:
if (m_cSocket.GetDomain() == AF_INET)
{
if((m_strType == "unicast") || (m_strType == "broadcast"))
m_cSocket.SetOption(IPPROTO_IP, IP_TTL, (char *)&m_iTTL,
sizeof(m_iTTL)) ;
else if(m_strType == "multicast")
m_cSocket.SetOption(IPPROTO_IP, IP_MULTICAST_TTL,
(char *)&m_iTTL, sizeof(m_iTTL));
}
it appears that the "if(m_strType == "multicast")" isn't been
matched... if you put the
m_cSocket.SetOption(IPPROTO_IP, IP_MULTICAST_TTL,
(char *)&m_iTTL, sizeof(m_iTTL));
before the second if in the code sample above, it is possible to alter
the ttl of the multicast stream. I've been poking around in the code
to figure out what value m_strType has, but am getting lost.... (C
programmer, first mess-around with C++ :)
Regards,
Richard
--
This is the streaming mailing-list, see http://www.videolan.org/streaming/
To unsubscribe, please read http://www.videolan.org/support/lists.html
If you are in trouble, please contact <postmaster at videolan.org>
More information about the streaming
mailing list