Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Same socket descriptor for two C-programs

Status
Not open for further replies.

svennkjetil

Programmer
Feb 1, 2001
11
NO
Hi.

I have two TCP/IP-programs written in C for receiving data from one client. Both programs receive from the same IP-address, but use port 2001 and 2002.

When I establish a socket I receive the same descriptor for both programs. Is this possible since they use different ports or is something wrong?
The same happens with the descriptor returned from function accept()...

I also often get the error: 239 connection refused.
What does this mean?

Svenn Kjetil



 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top