Question

I try to make an app that can make a connection into a FTP server. I've use Chilkat library to do this connection. The problem is, I want to test my app and make a wrong connection. So i make a connection into my FTP server, but using SSL connection (base on chilkat example in Chilkat sample code for implicit SSL connection)

FYI, I am not setting SSL in my FTP server. After I run my code on device, the app crashed, and the debugger showed SIGPIPE. I know SIGPIPE is because I made a wrong socket connection, but I dont know how to handle it. I have read an article about uncaught exception on this link, but I don't know how to implement these.

Can somebody tell me, how to handle these SIGPIPE exceptions?

Was it helpful?

Solution

Have a look at this answer: Prevent Sigpipes

When you ignore sigpipes your app won't crash anymore when recieving a sigpipe.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top