NSArray sortedArrayUsingSelector内存泄漏

时间:2011-07-26 12:05:13

标签: iphone memory-leaks nsarray selector

我收到包含sortedArrayUsingSelector定义的行的内存泄漏。有人知道可能是什么问题吗?

@property (nonatomic, retain) NSArray *indexLetters;
...
NSMutableDictionary *indexedCategories = [[NSMutableDictionary alloc] init];
...
self.indexLetters = [[indexedCategories allKeys] sortedArrayUsingSelector:@selector(compare:)];
[indexedCategories release];

1 个答案:

答案 0 :(得分:-1)

可能是因为您没有在indexLetters中发布dealloc变量。