[prev in list] [next in list] [prev in thread] [next in thread]
List: openjdk-2d-dev
Subject: Re: RFR: 8305072: Win32ShellFolder2.compareTo is inconsistent [v2]
From: Phil Race <prr () openjdk ! org>
Date: 2024-03-26 20:34:22
Message-ID: kG59XWfl8x5uX0zNn26lqJxXm9x1XLPohGpmm9xNGjc=.51d545cb-cda3-48db-b48f-bdb75bd4e843 () github ! com
[Download RAW message or body]
On Tue, 5 Mar 2024 17:40:01 GMT, Alexey Ivanov <aivanov@openjdk.org> wrote:
> > The implementation of `Win32ShellFolder2.compareTo` is inconsistent: there are \
> > cases where `a < b & b < c but a == c`
> > which *violates its general contract*.
> >
> > In particular, it happens for the personal folder (*Documents*) if it is listed \
> > *twice*: as a special and as a regular folder.
> > The evaluation performed by the submitter of the bug provided enough details to \
> > create a test, reproduce the problem and finally resolve it.
> > Without the fix, the regression test always fails:
> >
> > a < b & b < c but a >= c
> > where
> > a = C:\Users<user>\Documents(true)
> > b = C:\Users<user>(false)
> > c = C:\Users<user>\Documents(false)
> >
> > as well as for the reverse case: `a > b & b > c`.
> >
> > How it is possible to have the same folder in a list of files twice remains \
> > unknown. I believe it is another bug in JDK, however, no one has been able to \
> > reproduce it so far.
>
> Alexey Ivanov has updated the pull request incrementally with one additional commit \
> since the last revision:
> Handle fakePersonal on Windows 10
>
> The desktop folder on Windows 10 does not include
> the Personal (Documents) folder.
Marked as reviewed by prr (Reviewer).
-------------
PR Review: https://git.openjdk.org/jdk/pull/18126#pullrequestreview-1961661797
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic