• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Test for TCP port
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Test for TCP port


  • Subject: Re: Test for TCP port
  • From: "Heizer, Charles" <email@hidden>
  • Date: Fri, 08 Apr 2011 20:04:09 -0700
  • Acceptlanguage: en-US
  • Thread-topic: Test for TCP port

Thanks,
This is what I kind of suspected. Are there any wrappers around bsd socket to make it easier?

Thanks,
Charles



On Apr 8, 2011, at 5:17 PM, Dave Carrigan wrote:

>
> On Apr 8, 2011, at 3:26 PM, Heizer, Charles wrote:
>
>> What is the best way to test to see if a TCP port is reachable and will answer connections? I was trying to use NSSocketPort and NSConnection but I'm not getting a valid connection.
>
> You have to connect to it. Unfortunately, neither NSSocketPort nor NSConnection attempt to connect until you send data, so with those, you have no way of immediately knowing that anything is actually listening. The best way is to get down a level and use socket(2) and friends.
>
> --
> Dave Carrigan
> email@hidden
> Seattle, WA, USA
>

--
Charles Heizer
Systems Management Solutions Group
Lawrence Livermore National Laboratory
P: 925-422-0197



_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Test for TCP port
      • From: RenĂ© v Amerongen <email@hidden>
References: 
 >Test for TCP port (From: "Heizer, Charles" <email@hidden>)
 >Re: Test for TCP port (From: Dave Carrigan <email@hidden>)

  • Prev by Date: Re: NSDateFormatter setDoesRelativeDateFormatting: broken?
  • Next by Date: Re: Storing a block in a CF/NSMutableDictionary?
  • Previous by thread: Re: Test for TCP port
  • Next by thread: Re: Test for TCP port
  • Index(es):
    • Date
    • Thread