I get a abort() which I am not able to 'catch' in my code. Perhaps I am missing some understanding; can you give me some insight or perhaps help me with the abort() ?
Please note; the code works fine for thousands of users I have; but a very few (two now) have reported this crash.
First the code (simplified):
244: -(void)openBSDSocket:(NSString*)hostname useSSL:(bool)useSSL {
245: // Look up host
246: if ( (remoteHost = gethostbyname([hostName cStringUsingEncoding:NSUTF8StringEncoding])) == NULL ) {
247: [NSException raise:SOCKET_EX_HOST_NOT_FOUND format:SOCKET_EX_HOST_NOT_FOUND_F, strerror(errno)];
248: }
Caused this crash (dump)
Thread 34 Crashed:
0 libSystem.B.dylib 0x00007fff8550fb6e __semwait_signal_nocancel + 10
1 libSystem.B.dylib 0x00007fff8550fa70 nanosleep$NOCANCEL + 129
2 libSystem.B.dylib 0x00007fff8556c3c6 usleep$NOCANCEL + 57
3 libSystem.B.dylib 0x00007fff8558b97c abort + 93
4 libSystem.B.dylib 0x00007fff854a3615 free + 128
5 libSystem.B.dylib 0x00007fff854f409b _mdns_search + 1469
6 libSystem.B.dylib 0x00007fff854f8564 _mdns_hostbyname + 287
7 libSystem.B.dylib 0x00007fff854f826d search_host_byname + 139
8 libSystem.B.dylib 0x00007fff854f8186 gethostbyname + 98
9 com.NZBVortex.NZBVortex 0x0000000100021346 -[CFNetworkStream openBSDSocket::] + 246
All the openBSDSocket's are correctly wrapped with exception catched, which of course doesn't catch the abort()
Can you help me give some insight here?