Re: RFR: 8282270: java/awt/Robot Screen Capture tests fail after 8280861 [v2]

2022-03-08 Thread Maxim Kartashev
On Tue, 8 Mar 2022 04:50:49 GMT, Sergey Bylokhov wrote: > if the scale > 1 then you can use low precision -> if the scale is equal to 2 > then shift by two/four pixels or something like that? @mrserb I suppose I could do that, but then it wouldn't be much different from the existing tests that

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Thomas Stuefe
On Tue, 8 Mar 2022 15:54:45 GMT, Zhengyu Gu wrote: >> Please review this small patch that fixes a potential memory leak that >> exception return fails to release allocated `cacheDirs` >> >> Test: >> >> - [x] jdk_desktop on Linux x86_64 > > Zhengyu Gu has updated the pull request incrementally

Re: RFR: 8249592 : Robot.mouseMove moves cursor to incorrect location when display scale varies and Java runs in DPI Unaware mode [v3]

2022-03-08 Thread Sergey Bylokhov
On Tue, 8 Mar 2022 18:26:59 GMT, Rajat Mahajan wrote: >> 8249592 : Robot.mouseMove moves cursor to incorrect location when display >> scale varies and Java runs in DPI Unaware mode > > Rajat Mahajan has updated the pull request incrementally with one additional > commit since the last revision:

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Alexey Ivanov
On Tue, 8 Mar 2022 21:12:33 GMT, Zhengyu Gu wrote: >>> I think `NewStringUTF()` can throw OOM and also return `NULL`, just which >>> one you pick. >> >> Yes. >> >> But we're discussing whether a check for exception is necessary after >> `(*env)->SetObjectArrayElement`. > > `SetObjectArrayElem

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Zhengyu Gu
On Tue, 8 Mar 2022 21:05:13 GMT, Alexey Ivanov wrote: >> I think `NewStringUTF()` can throw OOM and also return `NULL`, just which >> one you pick. > >> I think `NewStringUTF()` can throw OOM and also return `NULL`, just which >> one you pick. > > Yes. > > But we're discussing whether a check

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Alexey Ivanov
On Tue, 8 Mar 2022 21:02:04 GMT, Zhengyu Gu wrote: > I think `NewStringUTF()` can throw OOM and also return `NULL`, just which one > you pick. Yes. But we're discussing whether a check for exception is necessary after `(*env)->SetObjectArrayElement`. - PR: https://git.openjdk.ja

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Zhengyu Gu
On Tue, 8 Mar 2022 20:57:27 GMT, Alexey Ivanov wrote: >>> ??? You want to check and cleanup if NewStringUTF fails. You only want to >>> call SetObjectElementArray if NewStringUTF succeeds. >> >> If the SetObjectArrayElement will throw an exception we will call the >> NewStringUTF while the exc

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Alexey Ivanov
On Tue, 8 Mar 2022 20:12:29 GMT, Sergey Bylokhov wrote: >> Can `SetObjectElementArray` raise an exception? >> The index is within the array length and we store a string. I assume >> `cacheDirArray` is a string array. > >> ??? You want to check and cleanup if NewStringUTF fails. You only want t

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Alexey Ivanov
On Tue, 8 Mar 2022 15:54:45 GMT, Zhengyu Gu wrote: >> Please review this small patch that fixes a potential memory leak that >> exception return fails to release allocated `cacheDirs` >> >> Test: >> >> - [x] jdk_desktop on Linux x86_64 > > Zhengyu Gu has updated the pull request incrementally

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Sergey Bylokhov
On Tue, 8 Mar 2022 13:37:44 GMT, Alexey Ivanov wrote: >> ??? You want to check and cleanup if NewStringUTF fails. You only want to >> call SetObjectElementArray if NewStringUTF succeeds. > > Can `SetObjectElementArray` raise an exception? > The index is within the array length and we store a s

Re: RFR: 8249592 : Robot.mouseMove moves cursor to incorrect location when display scale varies and Java runs in DPI Unaware mode [v2]

2022-03-08 Thread Rajat Mahajan
On Tue, 8 Mar 2022 03:51:40 GMT, Sergey Bylokhov wrote: >> Rajat Mahajan has updated the pull request incrementally with one additional >> commit since the last revision: >> >> removed stdlib.h, not needed > > src/java.desktop/windows/native/libawt/windows/awt_Robot.cpp line 53: > >> 51: >>

Re: RFR: 8249592 : Robot.mouseMove moves cursor to incorrect location when display scale varies and Java runs in DPI Unaware mode [v3]

2022-03-08 Thread Rajat Mahajan
> 8249592 : Robot.mouseMove moves cursor to incorrect location when display > scale varies and Java runs in DPI Unaware mode Rajat Mahajan has updated the pull request incrementally with one additional commit since the last revision: limit code to 80 characters per line - Change

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Zhengyu Gu
On Tue, 8 Mar 2022 15:58:57 GMT, Alexey Ivanov wrote: > > I did a quick grep, there are a few suspicious spots, e.g. > > [https://github.com/openjdk/jdk/blob/master/src/java.desktop/windows/native/libawt/windows/awt_Window.cpp#L2711](url), > > I have yet take a close look. > > It doesn't leak

Re: RFR: 8277922: Unable to click JCheckBox in JTable through Java Access Bridge [v2]

2022-03-08 Thread Alexey Ivanov
On Thu, 24 Feb 2022 12:02:00 GMT, Anton Litvinov wrote: >>> The reason of the issue is the fact that when the assistive technology >>> software tries to do "AccessibleAction" on "AccessibleContext" associated >>> with a cell with boolean data type in "JTable" component through Java >>> Access

Re: RFR: 8277922: Unable to click JCheckBox in JTable through Java Access Bridge [v2]

2022-03-08 Thread Alexey Ivanov
On Sat, 12 Feb 2022 00:52:26 GMT, Anton Litvinov wrote: >> src/java.desktop/share/classes/javax/swing/JTable.java line 5493: >> >>> 5491: } >>> 5492: >>> 5493: protected class AccessibleBooleanRenderer >> >> I guess the doAccessibleAction(i); should work in a similar way as som

Integrated: 8282234: Create a regression test for JDK-4532513

2022-03-08 Thread Manukumar V S
On Tue, 22 Feb 2022 15:47:20 GMT, Manukumar V S wrote: > Create a regression test for > [JDK-4532513](https://bugs.openjdk.java.net/browse/JDK-4532513). > This test verifies that the DefaultCaret doesn't requests focus in mouseClick > and mousePressed causing the associated input verifier to fi

Re: RFR: 8282270: java/awt/Robot Screen Capture tests fail after 8280861

2022-03-08 Thread Alexey Ivanov
On Thu, 24 Feb 2022 22:04:19 GMT, Alexey Ivanov wrote: >>> I submitted a job for testing the changes. >> >> Thanks a lot! > >> > I submitted a job for testing the changes. >> >> Thanks a lot! > > I got 1 failure out of 15 on Linux for > `java/awt/Robot/HiDPIScreenCapture/HiDPIRobotScreenCaptu

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Alexey Ivanov
On Tue, 8 Mar 2022 15:54:45 GMT, Zhengyu Gu wrote: >> Please review this small patch that fixes a potential memory leak that >> exception return fails to release allocated `cacheDirs` >> >> Test: >> >> - [x] jdk_desktop on Linux x86_64 > > Zhengyu Gu has updated the pull request incrementally

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-08 Thread Zhengyu Gu
> Please review this small patch that fixes a potential memory leak that > exception return fails to release allocated `cacheDirs` > > Test: > > - [x] jdk_desktop on Linux x86_64 Zhengyu Gu has updated the pull request incrementally with one additional commit since the last revision: mrserb

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig()

2022-03-08 Thread Zhengyu Gu
On Fri, 4 Mar 2022 13:25:12 GMT, Zhengyu Gu wrote: > Please review this small patch that fixes a potential memory leak that > exception return fails to release allocated `cacheDirs` > > Test: > > - [x] jdk_desktop on Linux x86_64 > > > The macros are used to hide the different syntax of c

Withdrawn: 8278348: [macos12] javax/swing/JTree/4908142/bug4908142.java fails in macos12

2022-03-08 Thread duke
On Tue, 14 Dec 2021 05:44:17 GMT, Prasanta Sadhukhan wrote: > Test seem to be failing in macos12.0.1 (although it does not seem to affect > 12.1) due to keypresses of "a", "a", "d" is not selecting "aad" but "ade" > which seems to point to the fact that 2 exclusive "a" keypress are considered

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig()

2022-03-08 Thread Alexey Ivanov
On Tue, 8 Mar 2022 12:20:38 GMT, David Holmes wrote: >> src/java.desktop/unix/native/common/awt/fontpath.c line 940: >> >>> 938: JNU_CHECK_EXCEPTION_AND_CLEANUP(env, >>> (*FcStrListDone)(cacheDirs)); >>> 939: >>> 940: (*env)->SetObjectArrayElement(env, cacheDirA

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig()

2022-03-08 Thread David Holmes
On Tue, 8 Mar 2022 09:18:01 GMT, Sergey Bylokhov wrote: >> Please review this small patch that fixes a potential memory leak that >> exception return fails to release allocated `cacheDirs` >> >> Test: >> >> - [x] jdk_desktop on Linux x86_64 > > src/java.desktop/unix/native/common/awt/fontpath.

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig()

2022-03-08 Thread David Holmes
On Tue, 8 Mar 2022 09:20:19 GMT, Sergey Bylokhov wrote: >> Please review this small patch that fixes a potential memory leak that >> exception return fails to release allocated `cacheDirs` >> >> Test: >> >> - [x] jdk_desktop on Linux x86_64 > > src/java.desktop/unix/native/common/awt/fontpath.

Re: RFR: 8282789: Create a regression test for the JTree usecase of JDK-4618767

2022-03-08 Thread Manukumar V S
On Tue, 8 Mar 2022 10:52:44 GMT, Manukumar V S wrote: > Create a regression test for the JTree usecase of > [JDK-4618767](https://bugs.openjdk.java.net/browse/JDK-4618767) > Context: Migrating tests from a closed tonga based test suite to open > regression based one. > > Issue identified in >

RFR: 8282789: Create a regression test for the JTree usecase of JDK-4618767

2022-03-08 Thread Manukumar V S
Create a regression test for the JTree usecase of [JDK-4618767](https://bugs.openjdk.java.net/browse/JDK-4618767) Context: Migrating tests from a closed tonga based test suite to open regression based one. Issue identified in [JDK-4618767](https://bugs.openjdk.java.net/browse/JDK-4618767): Typi

Re: RFR: 8282548: Create a regression test for JDK-4330998

2022-03-08 Thread Manukumar V S
On Tue, 8 Mar 2022 10:06:23 GMT, Manukumar V S wrote: > Create a regression test for > [JDK-4330998](https://bugs.openjdk.java.net/browse/JDK-4330998) > Context: Migrating tests from a closed tonga based test suite to open > regression based one. > > Issue tested: > When calling JEditorPane.se

RFR: 8282548: Create a regression test for JDK-4330998

2022-03-08 Thread Manukumar V S
Create a regression test for [JDK-4330998](https://bugs.openjdk.java.net/browse/JDK-4330998) Issue tested: When calling JEditorPane.setText(null), the following exception is thrown: java.lang.NullPointerException: at java.io.StringReader.(StringReader.java:38) Testing: Java 1.4.0 -> Tes

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig()

2022-03-08 Thread Sergey Bylokhov
On Fri, 4 Mar 2022 13:25:12 GMT, Zhengyu Gu wrote: > Please review this small patch that fixes a potential memory leak that > exception return fails to release allocated `cacheDirs` > > Test: > > - [x] jdk_desktop on Linux x86_64 src/java.desktop/unix/native/common/awt/fontpath.c line 938: >

RFR: JDK-8282778: Create a regression test for JDK-4699544

2022-03-08 Thread Srinivas Mandalika
Create a regression test for JDK-4699544 The subclass of javax.swing.JRootPane (AccessibleJRootPane) that implements the accessibility interface javax.accessibility.AccessibleComponent is derived from java.awt.AccessibleAWTComponent, which returns null for getAccessibleAt() because a component

RFR: JDK-8282777: Create a Regression test for JDK-4515031

2022-03-08 Thread Srinivas Mandalika
Create a Regression test for [JDK-4515031](https://bugs.openjdk.java.net/browse/JDK-4515031) The issue indicates the need for a a getAccessibleDescription being implemented for the JFileChooser. The test added verifies the same. - Commit messages: - 8282777:Create a Regression tes