Hi, Alan Thanks. Updated on same link http://cr.openjdk.java.net/~minqi/8194154/webrev1/ as your recommendation.
Yumin On Wed, Feb 14, 2018 at 4:42 AM, Alan Bateman <[email protected]> wrote: > On 14/02/2018 01:23, yumin qi wrote: > >> Hi, >> >> I have update the webrev: >> http://cr.openjdk.java.net/~minqi/8194154/webrev1/ < >> http://cr.openjdk.java.net/%7Eminqi/8194154/webrev1/> >> >> In this version, as suggested by Alan(thanks!), property of "user.dir" >> is cached and behave like it is 'read only'. The change made to *inux as >> well as windows. Since property of "user.dir" is cached, any changes via >> property setting for it has no effect. >> >> This looks much better but you've removed a permission check from the > Windows getUserPath implementation. That code the same permission check as > the resolve method in the Unix implementation. > > I think the test needs works. The simplest would be to call > getCanonicalFile before changing the system property, then call it after > and check that you an equal result. Also no need to hack the Properties > object, you can use System.setProperty instead. > > -Alan > > >
