Re: memory deallocation
Re: memory deallocation
- Subject: Re: memory deallocation
- From: Scott Ribe <email@hidden>
- Date: Sat, 04 Apr 2009 16:18:17 -0600
- Thread-topic: memory deallocation
> If for example I have a group of string #defines that are used in log
> messages, that means that I will have to malloc space for them the
> sprintf them to it, so I can be sure that I don't get that warning
> when deallocating the log messages.
That's a symptom of a bad design. You shouldn't be trying to deallocate
strings in code that has no idea how the strings were allocated in the first
place. You need to have a clear idea about "ownership" of all data.
--
Scott Ribe
email@hidden
http://www.killerbytes.com/
(303) 722-0567 voice
_______________________________________________
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