I have the following code that leaks. Instruments says that it is the rssParser object that is leaking. I “refresh” the XML feed and it runs the block and it leaks….
file.h
@interface TestAppDelegate : NSObject <UIApplicationDelegate> {
NSXMLParser *rssParser;
}
file.m
NSData *data = [ NSURLConnection sendSynchronousRequest:request returningResponse: nil error: nil ];
rssParser = [[NSXMLParser alloc] initWithData:data];
[rssParser setDelegate:self];
[rssParser setShouldProcessNamespaces:NO];
[rssParser setShouldReportNamespacePrefixes:NO];
[rssParser setShouldResolveExternalEntities:NO];
[rssParser parse];
[rssParser release];
Image of leak….
Apple have got back to me and this is a bug #6469143
Looks like they plan to fix for 4.0