Re: Application crashing ( Maybe I'm over releasing object? )
Re: Application crashing ( Maybe I'm over releasing object? )
- Subject: Re: Application crashing ( Maybe I'm over releasing object? )
- From: Graham Cox <email@hidden>
- Date: Wed, 20 Aug 2008 14:51:49 +1000
On 20 Aug 2008, at 2:40 pm, Nicolas Goles wrote:
Track *newTrack = [[Track alloc] init];
[albumsLibrary addTrackToLibrary:newTrack
withPath:fullPath];
I didn't spot anything immediately obvious, but what's this doing?
You alloc/init an object and DON'T release it as the rules say you
should. What happens inside -addTrackToLibrary:? On the face of it
this looks like a leak, rather than the error you reported, but it's
still a bug. If -addTrackToLibrary: is releasing it it shouldn't be,
it's not the object's owner.
cheers, Graham
_______________________________________________
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