Posted By: Void | Oct 29th, 2006 @ 8:54 PM
page 1 of 1
Comments: 1 | Views: 2537
Void
Void
A state of nonexistence

My application needs to listen for a TCP connection on all available network cards/IPs. Is there a way to do this without creating a seperate thread for each listener?

I thought 0.0.0.0 (IP Any) would do this but actualy it just picks the first IP/network card.

TIA

You don't mention what language you are doing this in, but in C# you do it like this, at least for the declaration:

System.Net.Sockets.TcpClient client = new System.Net.Sockets.TcpClient( new System.Net.IPEndPoint( System.Net.IPAddress.Any , 80 ) );

page 1 of 1
Comments: 1 | Views: 2537