-
Bug
-
Resolution: Fixed
-
P3
-
11.0.6, 15, 16, 17
-
b02
-
os_x
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8270895 | 17.0.1 | Christoph Langer | P3 | Resolved | Fixed | b03 |
JDK-8273354 | 11.0.14 | Martin Doerr | P3 | Resolved | Fixed | b01 |
JDK-8268905 | 11.0.13-oracle | Anton Litvinov | P3 | Resolved | Fixed | b01 |
JDK-8273687 | openjdk8u322 | Anton Litvinov | P3 | Resolved | Fixed | b01 |
JDK-8268970 | 8u311 | Anton Litvinov | P3 | Resolved | Fixed | b01 |
macOS 10.15.7
A DESCRIPTION OF THE PROBLEM :
If the method "java.awt.print.Printable.print​(Graphics, PageFormat, int)" throws "java.lang.RuntimeException" or "java.awt.print.PrinterException" during the call "java.awt.print.PrinterJob.print()", then the exception is swallowed by JDK and a user cannot learn that printing failed and what caused failure of printing, because "PrinterJob.print()" method does not throw "PrinterException" or the occurred exception is not reported by JDK through the error stream.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Compile and run the attached to this bug test case "ExceptionFromPrintableIsIgnored.java".
2. In the shown window of the test case select a type of an exception that should be thrown from "java.awt.print.Printable.print" method and select on which thread the method "java.awt.print.PrinterJob.print" should be executed.
3. Click "Run Test" button, in the shown dialog select printer and initiate printing.
The bug is reproduced, if no exception is displayed in the text area "Test Results:" and no exception is reported in the console at the same time.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED - A printed out stack trace or a thrown exception to indicate to the developer where the problem lies or at least why printing cannot complete normally.
ACTUAL - The exception is swallowed.
- backported by
-
JDK-8268905 [macOS] Exception from "Printable.print" is swallowed during "PrinterJob.print"
- Resolved
-
JDK-8268970 [macOS] Exception from "Printable.print" is swallowed during "PrinterJob.print"
- Resolved
-
JDK-8270895 [macOS] Exception from "Printable.print" is swallowed during "PrinterJob.print"
- Resolved
-
JDK-8273354 [macOS] Exception from "Printable.print" is swallowed during "PrinterJob.print"
- Resolved
-
JDK-8273687 [macOS] Exception from "Printable.print" is swallowed during "PrinterJob.print"
- Resolved
- relates to
-
JDK-8268675 RTE from "Printable.print" propagates through "PrinterJob.print"
- Open
-
JDK-8296920 Regression Test DialogOrient.java fails on MacOS
- Resolved
- links to
-
Commit openjdk/jdk11u-dev/1645dbe4
-
Commit openjdk/jdk17u/d684356d
-
Commit openjdk/jdk/c0b4407d
-
Review openjdk/jdk11u-dev/311
-
Review openjdk/jdk17u/4
-
Review openjdk/jdk/4036