Discussion:
INDY idIPMCastClient , multiple NICs
(too old to reply)
Ernst-Wichard Budde
2008-07-16 08:35:05 UTC
Permalink
I am trying to use the INDY idIPMCastClient component for Multicast
communication. When only one Network Adapter (NIC) is active, I can actually
receive Multicast messages; but not when more than one NIC is active.

I tried to put the NIC IP Address that I want to use to the BINDINGS of the
idIPMCastClient component, but that does not work, either.

Looking at the code of "procedure TIdIPMCastListenerThread.Run;" I am
surprised to see that inside a loop over all bindings, revfrom(..) is
called. Because this call is blocking, the first binding that does not
receive a message will block the tread forever!!

I hope that I just did not really understand the code section.

Can anyone tell me how I can receive Multicast messages in multiple NIC
environment?



Thanks

Ernst
Remy Lebeau (TeamB)
2008-07-16 16:21:18 UTC
Permalink
Post by Ernst-Wichard Budde
Looking at the code of "procedure TIdIPMCastListenerThread.Run;"
I am surprised to see that inside a loop over all bindings, revfrom(..)
is called.
Which version of Indy are you using? What you describe is true for Indy 9
and earlier. In Indy 10, each Binding has its own thread now.
Post by Ernst-Wichard Budde
Because this call is blocking, the first binding that does not receive
a message will block the tread forever!!
It shouldn't. Run() calls recvfrom() only on connections that have been
signalled as being readable, as indicated by a previous call to select().
In other words, only connections that have pending data will be read from.


Gambit

Loading...