On Aug 25, 2012, at 7:03 AM, Jens Alfke <j...@mooseyard.com> wrote:
> On Aug 24, 2012, at 8:59 PM, koko <k...@highrolls.net> wrote:
>>      const UInt8 *cpath = (const UInt8 *)[path 
>> cStringUsingEncoding:NSUTF8StringEncoding];
> 
> -UTF8String is shorter.

 Both of these are wrong, though. You should *always* use 
-fileSystemRepresentation when you need a C-string representation of a path. 
Otherwise you might get decomposed characters that don't match the actual way 
the characters are stored on disk, and will create a second file with an 
almost-indistinguishable name.

Cheers,
-- Uli Kusterer
"The Witnesses of TeachText are everywhere..."
http://www.zathras.de


_______________________________________________

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

This email sent to arch...@mail-archive.com

Reply via email to