Re: -[NSString stringWithCString:encoding:] memory management question
Re: -[NSString stringWithCString:encoding:] memory management question
- Subject: Re: -[NSString stringWithCString:encoding:] memory management question
- From: "Hank Heijink (Mailinglists)" <email@hidden>
- Date: Wed, 11 Nov 2009 20:25:00 -0500
True. I'd better check for that - thanks! However, I'd have gotten a
crash at that line, not confused memory management. I'm not catching
any exceptions that would muffle this one.
Hank
On Nov 11, 2009, at 5:07 PM, Aki Inoue wrote:
Another possibility.
Since you're asking to instantiate the string with
NSASCIIStringEncoding, the method could return nil when it fails to
convert the pBuffer contents (i.e. non-ASCII bytes above 0x7F).
That would lead to trigger exception raises at the line immediately
following. That might've been confusing your memory management
somewhere else.
Aki
_______________________________________________
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