Releasing NSSearchPathForDirectoriesInDomain causes crash
Releasing NSSearchPathForDirectoriesInDomain causes crash
- Subject: Releasing NSSearchPathForDirectoriesInDomain causes crash
- From: Anthony Smith <email@hidden>
- Date: Wed, 30 Sep 2009 22:07:22 -0400
Does anybody know why releasing the NSArray obtained from
NSSearchPathForDirectoriesInDomain causes my iPhone app to crash?
Here's my code:
+ (NSString *)dataFilePath:(NSString *)filename {
NSArray *paths = NSSearchPathForDirectoriesInDomains
(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *directory = [paths objectAtIndex:0];
[paths release];
return [directory stringByAppendingPathComponent:filename];
}Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden