Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

HFS Alias of a Hebrew (right-to-left) POSIX pathname?



I have a unix-style file path as a CFStringRef, and need the HFS alias for that file.

Here's what I'm using :

CFURLRef url = CFURLCreateWithFileSystemPath(NULL, path, kCFURLPOSIXPathStyle, NO);
CFStringRef* hfsPath = CFURLCopyFileSystemPath(url, kCFURLHFSPathStyle);



Works great for left-to-right pathnames, including Chinese, Japanese, etc.
However, it falls over for Hebrew. I'm totally unfamiliar with how OS X handles right-to-left filenames, and I'm struggling to fix this.




I'm pulling the POSIX filepath from iTunes XML. It might look something like this :
/Users/jon/Music/iTunes/iTunes Music/test/test/02 שיחכגן'שך.mp3


(apologies to those that can actually read hebrew - that filename was just me mashing the keyboard)

Finder shows the filename as "mp3.{hebrew bit} 02" - however, NSFileManager confirms that the file exists, so I'm assuming that Finder is applying its own formatting here.

I'm then passing the hfsPath through Applescript, where it complains that it doesn't exist.
For debugging, it would help if I could test whether Carbon thinks that the HFS path exists - but I can't figure out how to do that. Is there a FS function to test whether a file exists, given an HFS-style filename?




Any suggestions on working with right-to-left HFS paths would be greatly appreciated...
Jon _______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden


This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.