RFR: 8278472: Invalid value set to CANDIDATEFORM structure
Sergey Bylokhov
serb at openjdk.java.net
Wed Jan 19 23:16:48 UTC 2022
On Wed, 19 Jan 2022 20:14:34 GMT, Alexey Ivanov <aivanov at openjdk.org> wrote:
> According to the Windows API reference, `dwStyle` of [`CANDIDATEFORM`](https://docs.microsoft.com/en-us/windows/win32/api/imm/ns-imm-candidateform) structure should be set to `CFS_CANDIDATEPOS` or `CFS_EXCLUDE`. So, `CFS_POINT` is wrong here.
>
> There are two instances in `AwtComponent::SetCandidateWindow` in [`awt_Component.cpp`](https://github.com/openjdk/jdk/blob/f90425a1cbbc686045c87086af586e62f05f6c49/src/java.desktop/windows/native/libawt/windows/awt_Component.cpp#L3914) where the incorrect value is used.
>
> Initially, I created this PR for jdk18. [It was suggested](https://github.com/openjdk/jdk18/pull/54#issuecomment-1006432326) to place this fix into the mainline, so this a continuation to [jdk18/pull/54](https://github.com/openjdk/jdk18/pull/54).
This change was done under https://bugs.openjdk.java.net/browse/JDK-8147842 where the CFS_CANDIDATEPOS was changed to the CFS_POINT. Please check that the old bug will not be reproduced again.
see http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/8d42ecfa68a3
-------------
PR: https://git.openjdk.java.net/jdk/pull/7146
More information about the client-libs-dev
mailing list