I have an encoding syntax error that crashes an app with a "*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** +[NSString stringWithCString:encoding:]: NULL cString'
" crash
here's the code:
apparently there's a double conversion occurring and that's why the call to cStringUsingEncoding:NSISOLatin1StringEncoding returns NULL).
Any idea how to fix this?
thanks!
" crash
here's the code:
Code:
// encoding fix
cell.titleLabel.text = [[NSString stringWithCString:[[item objectForKey:@"main_tag"] cStringUsingEncoding:NSISOLatin1StringEncoding]]capitalizedString];
apparently there's a double conversion occurring and that's why the call to cStringUsingEncoding:NSISOLatin1StringEncoding returns NULL).
Any idea how to fix this?
thanks!
Last edited by a moderator: