On 4 Jan 2005, at 11:41, Bob Ippolito wrote:
And finally: Is there any other way to find the true spelling of a file
except than a linear search with opendir()/readdir()/closedir() ?

Yes, definitely. I'm positive you can do this with CoreServices, but I'm not sure it's portable to Darwin (not Mac OS X). I'm sure there is some Darwin-compatible way of doing it, but I don't know it off the top of my head. I'll try to remember to look into it if nobody else finds it first.

I haven't used pure darwin, but I assume it has support for FSRefs, right? Then you could use FSPathMakeRef() to turn the filename into an FSRef, and then FSGetCatalogInfo() to get the true filename.
--
Jack Jansen, <[EMAIL PROTECTED]>, http://www.cwi.nl/~jack
If I can't dance I don't want to be part of your revolution -- Emma Goldman


_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to