Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8039412

Stack overflow on Linux using DialogTypeSelection.NATIVE

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3
    • 9
    • 8, 9
    • client-libs
    • None
    • 2d
    • b96

    Backports

      Description

        This program shows a stack over flow ..
        import java.awt.print.*;
        import javax.print.*;
        import javax.print.attribute.*;
        import javax.print.attribute.standard.*;

        public class PD {

            public static void main(String args[]) {
               PrinterJob job = PrinterJob.getPrinterJob();
               if (job == null) {
                   return;
               }
               PrintRequestAttributeSet pSet =
                    new HashPrintRequestAttributeSet();
               pSet.add(DialogTypeSelection.NATIVE);
               job.printDialog(pSet);
               job.pageDialog(pSet);
           }
        }

        Exception in thread "main" java.lang.StackOverflowError
        at java.security.AccessController.doPrivileged(Native Method)
        at sun.print.RasterPrinterJob.pageDialog(RasterPrinterJob.java:720)
        at sun.print.RasterPrinterJob.pageDialog(RasterPrinterJob.java:762)
        at sun.print.RasterPrinterJob.pageDialog(RasterPrinterJob.java:737)
        at sun.print.RasterPrinterJob.pageDialog(RasterPrinterJob.java:762)
        at sun.print.RasterPrinterJob.pageDialog(RasterPrinterJob.java:737)


        Attachments

          Issue Links

            Activity

              People

                psadhukhan Prasanta Sadhukhan
                prr Philip Race
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: