Re: Problems with double freeing.
Re: Problems with double freeing.
- Subject: Re: Problems with double freeing.
- From: j o a r <email@hidden>
- Date: Sun, 20 Nov 2005 16:49:35 +0100
On 20 nov 2005, at 15.45, Tom Jones wrote:
NSArray * theLines = [[[NSString stringWithContentsOfFile:
fileName] componentsSeparatedByString:@"\r"]autorelease];
You made a couple of errors like this one. The array returned to you
from "componentsSeparatedByString:" should not be autoreleased.
Remember the basic rule: You should only release if you alloc / copy.
As there is no alloc / copy in the method name
"componentsSeparatedByString:", you should not release / autorelease
the returned value.
j o a r
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden