Home > other >  LAN address respectively, why
LAN address respectively, why

Time:10-10

According to online video has written a LAN chat program, , besides images show the other is a While loop, print the words! Results can only chat on your computer, no other computers in the connection is out directly, others said IP address problem, seek counsel, server, client IP address, respectively, to fill what!

CodePudding user response:

Rubber touching ~ ~ ~

CodePudding user response:


Before the school computer

CodePudding user response:

Where is the server, the IP address is fill in the server machine IP
The client to the server, so the client fill in the server's IP
Server machine may have multiple IP, so the server is to specify the IP, this value is usually use INADDR_ANY

The client's IP does not need to know, because each time the connection is a client initiated first, so once a connection, the server will know the client's IP
  • Related