Search code examples
objective-ccocoaasyncsocket

NSTimer not working with AsyncSocket library


I am using the AsyncSocket library and I tried creating an NSTimer but it is not firing. When I remove the Async socket code, my timer works. I am pretty sure AsyncSockets is causing this, so how can I use NSTimers and what might be the cause of this?


Solution

  • I found a method addTimerToRunloop in the AsyncSocket library that fixes this.