Re: Unicode filenames with Apple File System and UIManagedDocument
Re: Unicode filenames with Apple File System and UIManagedDocument
- Subject: Re: Unicode filenames with Apple File System and UIManagedDocument
- From: Jens Alfke <email@hidden>
- Date: Mon, 20 Mar 2017 22:06:43 -0700
> On Mar 20, 2017, at 2:23 PM, email@hidden wrote:
>
> NSURL *url = [[self courseDirectory] URLByAppendingPathComponent:name];
There’s nothing wrong with that call; it’s the canonical way to add a path component to a URL, filesystem or not.
> NSURL *url = [NSURL fileURLWithFileSystemRepresentation:[name fileSystemRepresentation] isDirectory:YES relativeToURL:[self courseDirectory]];
This call doesn’t make sense. You’re converting to filesystem representation and then back again, for no reason.
What Apple suggested is to Unicode-normalize the filename before adding it to the URL. Did you try doing that?
—Jens
_______________________________________________
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