You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bu...@apache.org on 2021/09/19 11:10:56 UTC

[Bug 65499] [performance] Avoid File.getCanonicalPath

https://bz.apache.org/bugzilla/show_bug.cgi?id=65499

--- Comment #3 from Stefan Bodewig <bo...@apache.org> ---
isSameFile is OS dependent and this is correct for the way things are used by
Ant. We really want to know whether the current OS believes the two paths to
point to the same file.

In Ant's case it is possible that neither exists so the point is different from
how the code is used by Eclipse.

Actually, Java has started to behave differently WRT to special Windows
devices. The details are escaping me but we introduced discardOutput to <exec>
and friends as the old way of directing output to NUL on Windows didn't work as
it used to anymore. So I'm not quite sure if/how isSameFile behaves for the
special devices and whether it depend on the Java version - historically Ant's
code completely lacked any special handling of these devices.

-- 
You are receiving this mail because:
You are the assignee for the bug.