<div>Hello Ross,</div>
<div> </div>
<div>Thanks for taking time in responding to my question. </div>
<div> </div>
<div>We are using Live Media library on Linux. I am not clear when you say it is often an operating system issue. Isn't it the responsibility of the application to bind to a pariticular address if it wants too? If a multicast application needs to only receive traffic on a particular multicast address, it will have to bind to that address?
</div>
<div> </div>
<div>Also, regarding your other comment "
<div>This is bogus, because the default value of "ReceivingInterfaceAddr" *is* INADDR_ANY. I.e., you'll get the same effect as your proposed change if you don't set "ReceivingInterfaceAddr" at all."
</div>
<div> </div>
<div>We are planning to set the ReceivingInterfaceAddr to our multicast address and it does work for us. Also, this change doesn't change your default behavior (where it is set to NULL) and thus wont break any existing applications.
</div>
<div> </div>
<div>However, I did notice that after setting ReceivingInterfaceAddr to a multicast address, ourSourceAddressForMulticast() in Groupsock.cpp is failing with "This computer has an invalid IP address:" error. I am in the process of debugging why this error happens. Any hints on this as well?
</div>
<div> </div>
<div>Once again, I appreciate your help here.</div>
<div> </div>
<div>Best,</div>
<div>-Sanjeev</div></div>
<div>---------- Forwarded message ----------<br>From: Ross Finlayson <<a href="mailto:finlayson@live555.com">finlayson@live555.com</a>><br>To: LIVE555 Streaming Media - development & use <<a href="mailto:live-devel@ns.live555.com">
live-devel@ns.live555.com</a>><br>Date: Tue, 3 Oct 2006 02:55:07 -0700<br>Subject: Re: [Live-devel] Groupsock doesn't bind to Multicast Address<br> </div>
<div>
<blockquote type="cite">I am relatively new user to the Live Media library. In our application, we would like to bind to a multicast address in addition to binding to the local port number. This is so that we *only* receive packets destined for a given
<u> Multicast address & port</u> combination and prevent other datagrams destined for that same port from being deliverd to our socket.</blockquote>
<div><br> </div>
<div>This is often an operating system issue. Some OSs work the way you want; others do not.</div>
<div><br> </div>
<blockquote type="cite">// change imr.imr_interface.s_addr = ReceivingInterfaceAddr; to following:</blockquote>
<blockquote type="cite"> </blockquote>
<blockquote type="cite">if (IN_MULTICAST(ntohl(ReceivingInterfaceAddr))) {<br> // Bound to MULTICAST Address, so use INADDR_ANY as the i/f address<br> imr.imr_interface.s_addr = INADDR_ANY;<br> }<br> else {<br> // Bound to UNICAST Address, so use this address as the i/f address
<br> imr.imr_interface.s_addr = ReceivingInterfaceAddr;<br> }</blockquote>
<div><br> </div>
<div>This is bogus, because the default value of "ReceivingInterfaceAddr" *is* INADDR_ANY. I.e., you'll get the same effect as your proposed change if you don't set "ReceivingInterfaceAddr" at all.</div>
<pre>--
</pre>
<div><br>Ross Finlayson<br>Live Networks, Inc.<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.live555.com/" target="_blank">http://www.live555.com/</a></div></div><br><br>