开发者

NSMutableArray leaks

I am trying the create a NSMutableArray by reading the contents of a file.

NSString *filePath = FILE_PATH;

NSMutableArray *tempArr = [[NSMutableArray alloc] initWithContentsOfFile:filePath];

    ...

   [tempArr release];

But i am getting memory leaks in the line where i am alloca开发者_高级运维ting the array.

What is the bug in the code ?

Thanks


As Vladimir said the problem is between those lines. Leaks showing the leak where the variable was created. But in fact you're over-retaining that array somewhere. double check your code.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜