RFR: 8194154: JDK crashes parsing path string contains '//' on linux

yumin qi yumin.qi at gmail.com
Wed Feb 14 01:23:07 UTC 2018


  I have update the webrev:

  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.


On Wed, Feb 7, 2018 at 10:54 PM, Alan Bateman <Alan.Bateman at oracle.com>

> On 07/02/2018 20:10, yumin qi wrote:
>> Hi,
>>    Please review the fix (extra small) for:
>>    bug 8194154: https://bugs.openjdk.java.net/browse/JDK-8194154
>>    webrev: http://cr.openjdk.java.net/~minqi/8194154/
>>    Summary: canonicalize will check and fold double (or more) slashes, but
>> in function collapsible(char*) and splitNames(char*, char**), it failed to
>> process strings like "//". This results in the former does not give a
>> correct number of substrings and the later does not give a correct array
>> of
>> substrings. The fix add a check if the character is '/' after a '/'.
>> The JDK has never supported setting user.dir in this way (it breaks
> several things). There is a thread discussing this on core-libs-dev so best
> to bring it to that mailing list to discuss again.
> -Alan

More information about the core-libs-dev mailing list