Thread: Winsock Question

  1. #1
    Refugee face_master's Avatar
    Join Date
    Aug 2001
    Posts
    2,052

    Winsock Question

    Assuming that all of the code is done for setting up Winsock is done, how would you check if a given ip is active/online?

    Thanks
    -Chris

  2. #2
    Registered User
    Join Date
    Feb 2002
    Posts
    114
    ping? pong!

    Send junk data to the pingport of the remove computer, if you get response the ip is active. Also, if you do a connect try, and get an error as result, the ip isn't active. This could be a problem though, because the connect must time out before it can determin that the ip wasn't active (or it could have been, but just doesn't accept connection on thar port). So ping is the way to go.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. another do while question
    By kbpsu in forum C++ Programming
    Replies: 3
    Last Post: 03-23-2009, 12:14 PM
  2. winsock
    By pode in forum Networking/Device Communication
    Replies: 2
    Last Post: 09-26-2003, 12:45 AM
  3. opengl DC question
    By SAMSAM in forum Game Programming
    Replies: 6
    Last Post: 02-26-2003, 09:22 PM
  4. Very simple question, problem in my Code.
    By Vber in forum C Programming
    Replies: 7
    Last Post: 11-16-2002, 03:57 PM
  5. Determining Data Size For Network Send/Rec :: Winsock
    By kuphryn in forum Windows Programming
    Replies: 6
    Last Post: 05-07-2002, 09:01 PM