This is maybe not a pure Tomcat question, but I am running a servlet on
Tomcat which uses javax.swing, to resize jpeg images, but which does not,
of course, want to display those images. This throws an exception, due to
a bug in the JDK 1.4.
The exception is:
Exception in thread "main" java.lang.InternalError: Can't connect to X11
window server using ':0,0' as the value of the DISPLAY variable.
at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
at sun.awt.X11GraphicsEnvironment.<clinit><>(11GraphicsEnvironment.java:126)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:130)
at java.awt.Toolkit#2.run(Toolket.java:712)
at java.security.AccessController.doPrivileged(Native Method)
at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:703)
at javax.swing.ImageIcon.(init>(ImageIcon.java:81)
at javax.swing.ImageIcon.<init>(ImageIcon.java:107)
ps aux reveals: "/etc/X11/X -auth /var/lib/kdm/authfiles/A:0-0Dqymv"
Anyone know the command I need to use to solve this, if any? I would
prefer not to use a virtual X11 system, or to build a substitute Toolkit
for the JDK.
Thanks,
Micael
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>