Matthew Young - 2009-07-28

running on Solaris [5.10 Generic_138888-07 sun4u sparc SUNW,Sun-Fire-880]....

Using JSCH via the Ant (version 1.7.1) scp task and Java 1.5.0_18.  Getting a HeadlessException thrown while pulling down a tar file from a remote machine:

     -->> returning Frame NULL
     java.awt.HeadlessException:
     No X11 DISPLAY variable was set,
     but this program performed an operation which requires it.

The exception is casted twice but the execution continues and the file is transferred.  This is not the case in Java 1.4.  If the java.awt.headless system property is set to true the following error text is associated with HeadlessException:

     -->> returning Frame NULL
     java.awt.HeadlessException
        at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:159)
        at java.awt.Window.<init>(Window.java:318)
        at java.awt.Frame.<init>(Frame.java:419)
        at java.awt.Frame.<init>(Frame.java:384)
        at com.trend.iwss.jscan.runtime.BaseDialog.getActiveFrame(BaseDialog.java:75)
        at com.trend.iwss.jscan.runtime.AllowDialog.make(AllowDialog.java:32)
        at com.trend.iwss.jscan.runtime.PolicyRuntime.showAllowDialog(PolicyRuntime.java:325)

Again the file transfers fine but the text is easily read as an error.  Anyway to handle the HeadlessException in a more gentler way?  Let SCP (secure copy) disable X11 forwarding?