This code does not cause problems with the analyzer:
static NSMutableDictionary *itemsDictionary;
- (void)addCategory:(NSString*)category {
NSMutableArray *itemsArray = [[NSMutableArray alloc] initWithCapacity:1];
if (category) {
[itemsDictionary setObject:itemsArray forKey:category];
}
[self dismissModalViewControllerAnimated:YES];
[itemsArray release];
}
Can you post the exact wording (or perhaps a screenshot) of the warning you see?
source
share