0

I've just started running (what I thought was) a basic asyncsocket in my objective-c app and I'm getting the didAcceptNewSocket: message when connecting with telnet, but then I'm abruptly disconnected ("Connection closed by foreign host") without reaching the didConnectToHost: message. It works fine in the example and I've tried to replicate everything I see there to no avail.

Is there some simple pitfall I should be avoiding? Any other way I can debug this problem?

Nick
  • 9,792
  • 7
  • 50
  • 60

1 Answers1

1

In this case, I was using the wrong delegate methods copied/pasted from some other site. Always check your headers!

Nick
  • 9,792
  • 7
  • 50
  • 60
  • I am having the same issue but I copy and pasted my methods from the header files so I doubt it is that. Do you know any other reason why this might be happening? – ddelnano Jan 12 '15 at 12:24