RFR: 8257809: JNI warnings from Toolkit JPEG image decoding

2020-12-19 Thread Phil Race
The fix is to reverse the order of acquisition to get dst before src so that the call to GetArrayLength() comes first. This also necessitates moving the RELEASE_ARRAYS() call on an error condition to the new "2nd" block. The new regression test passes on all platforms and all the other headless

Integrated: 8257853: Remove dependencies on JNF's JNI utility functions in AWT and 2D code

2020-12-19 Thread Phil Race
On Mon, 7 Dec 2020 21:24:57 GMT, Phil Race wrote: > This defines some macros to support declaring and initialising statically > allocated instances of jclass, jmethodID and jfieldID > and changes many existing uses of JNF macros/functions to use these instead. > Then calls to JNFCall* and JNFNew

Integrated: 8258006: Replaces while cycles with iterator with enhanced for in java.desktop

2020-12-19 Thread Andrey Turbanov
On Wed, 2 Dec 2020 19:23:28 GMT, Andrey Turbanov wrote: > There are few places in code where manual `while` loop is used with > `Iterator` to iterate over `Collection`. > Instead of manual `while` cycles it's preferred to use _enhanced-for_ cycle > instead: it's less verbose, makes code easier

Re: RFR: 8258006: Replaces while cycles with iterator with enhanced for in java.desktop [v2]

2020-12-19 Thread Sergey Bylokhov
On Tue, 15 Dec 2020 15:24:03 GMT, Andrey Turbanov wrote: >> There are few places in code where manual `while` loop is used with >> `Iterator` to iterate over `Collection`. >> Instead of manual `while` cycles it's preferred to use _enhanced-for_ cycle >> instead: it's less verbose, makes code e

Integrated: 8257584: [macos] NullPointerException originating from LWCToolkit.java

2020-12-19 Thread Alexander Zuev
On Wed, 16 Dec 2020 02:58:00 GMT, Alexander Zuev wrote: > 8257584: [macos] NullPointerException originating from LWCToolkit.java This pull request has now been integrated. Changeset: dc7f01f4 Author:Alexander Zuev URL: https://git.openjdk.java.net/jdk/commit/dc7f01f4 Stats: 15 li

Re: RFR: 8257853: Remove dependencies on JNF's JNI utility functions in AWT and 2D code [v7]

2020-12-19 Thread Prasanta Sadhukhan
On Fri, 18 Dec 2020 19:24:15 GMT, Phil Race wrote: >> This defines some macros to support declaring and initialising statically >> allocated instances of jclass, jmethodID and jfieldID >> and changes many existing uses of JNF macros/functions to use these instead. >> Then calls to JNFCall* and J