GlobalLock has a return value that indicates errors; this should be handled.

While looking into this, in Java_sun_awt_windows_WPrinterJob_deviceStartPage  a 
free call was found that is not placed correctly and can lead to leaks.

---------
- [x] I confirm that I make this contribution in accordance with the [OpenJDK 
Interim AI Policy](https://openjdk.org/legal/ai).

-------------

Commit messages:
 - JDK-8389674

Changes: https://git.openjdk.org/jdk/pull/32206/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=32206&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8389674
  Stats: 181 lines in 6 files changed: 97 ins; 25 del; 59 mod
  Patch: https://git.openjdk.org/jdk/pull/32206.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/32206/head:pull/32206

PR: https://git.openjdk.org/jdk/pull/32206

Reply via email to