<div class="gmail_quote">On Sun, Sep 26, 2010 at 06:36, Paul Moore <span dir="ltr"><<a href="mailto:p.f.moore@gmail.com">p.f.moore@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On 26 September 2010 09:01, Paul Moore <<a href="mailto:p.f.moore@gmail.com">p.f.moore@gmail.com</a>> wrote:<br>
> On 25 September 2010 23:57, Greg Ewing <<a href="mailto:greg.ewing@canterbury.ac.nz">greg.ewing@canterbury.ac.nz</a>> wrote:<br>
>> Paul Moore wrote:<br>
>><br>
>>> Windows has (I believe) user definable filesystems, too, but the OS<br>
>>> has "get me the real filename" style calls,<br>
>><br>
>> Does it really, though? The suggestions I've seen for doing<br>
>> this involve abusing the short/long filename translation<br>
>> machinery, and I'm not sure they're guaranteed to return the<br>
>> actual case rather than something that happens to work.<br>
><br>
> There's another call available. I've been too lazy to go and look it<br>
> up, but I'll do so sometime today.<br><br></div>
GetFinalPathNameByHandle works, and is documented to do so, but (a) it<br>
works on an open file handle, so you need to open the file, and (b)<br>
it's Vista and later only...</blockquote><div><br></div><div>FYI, this is currently exposed as nt._getfinalpathname, and is used for os.path.samefile on Vista and beyond.</div></div>