iOS8 NSXMLParser crash -


i had crash in nsxmlparser

* terminating app due uncaught exception 'nsinternalinconsistencyexception', reason: 'nsxmlparser not support reentrant parsing.'

here code

nsstring *wrappedsnippet = [nsstring stringwithformat:@"<html>%@</html>", self.snippet]; nsxmlparser *parser = [[nsxmlparser alloc] initwithdata:[wrappedsnippet datausingencoding:nsutf8stringencoding]]; [parser setdelegate:self]; [parser parse]; 

app crashes on last line.

note, works perfect on ios7!

ios8 throws exception previous versions caught , handled in background.
see manual ios 5 nsxmlparser thread safe not reentrant! make sure aren't calling parse nsxmlparser delegate. "self" in case.


Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -