Question:
In my cocoa application, i am trying to connect and upload files to server. For that i'm using below given code for connecting the sftp.
success = [sftp Connect: hostname port: [NSNumber numberWithInt: port]];
Sometimes it's not connecting with my server. but my server is available for use. if this (success = NO) happens once in my application, i can't able to connect with server even after multiple retries. But i can able to connect with server after restarting the app. Can anyone provide the solution to accomplish the problem and connect with sftp server without interruption/restarting the app?