> 
> On 30 Apr 2008, at 12:35, Trygve Inda wrote:
> 
>> So why the need for + dataWithBytesNoCopy:length:freeWhenDone: ?
>> 
>> It would seem that if freeWhenDone is YES, these are identical calls?
> 
> Because sometimes you might want to use NO. i.e maybe its a non-
> malloced buffer that you want to treat as NSData, or maybe just a
> malloced buffer that you need to pass to some method that expects an
> NSData, but you don't want to have to duplicate the entire buffer.

I guess the freeWhenDone is a newer call then, otherwise it'd make more
sense to only have the freeWhenDone variant.

Thanks,

Trygve


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to