United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6812285 PIT : WARNING: Exception on Toolkit thread java.lang.UnsatisfiedLinkError: sun.awt.X11.XlibW
JDK-6812285 : PIT : WARNING: Exception on Toolkit thread java.lang.UnsatisfiedLinkError: sun.awt.X11.XlibW

Details
Type:
Bug
Submit Date:
2009-03-03
Status:
Closed
Updated Date:
2011-01-19
Project Name:
JDK
Resolved Date:
2009-05-15
Component:
client-libs
OS:
solaris_10
Sub-Component:
java.awt
CPU:
sparc
Priority:
P1
Resolution:
Fixed
Affected Versions:
6u14
Fixed Versions:
6u14 (b03)

Related Reports
Backport:
Relates:

Sub Tasks

Description
I have a frame to which  i have added a button. The whole process i am doing in toolkit thread  as follows
 Toolkit.getDefaultToolkit().getSystemEventQueue().invokeAndWait(new Runnable() {
	public void run() {
		// create a frame & adding the button to it.
	}
}

When the frame is visible , i press on the button. I see the following warning.  
WARNING: Exception on Toolkit thread
java.lang.UnsatisfiedLinkError: sun.awt.X11.XlibWrapper.XLookupStringShort(J)I
	at sun.awt.X11.XlibWrapper.XLookupStringShort(Native Method)
	at sun.awt.X11.XWindow.handleKeyPress(XWindow.java:1048)
	at sun.awt.X11.XWindow.handleKeyPress(XWindow.java:1008)
	at sun.awt.X11.XFocusProxyWindow.handleKeyPress(XFocusProxyWindow.java:66)
	at sun.awt.X11.XBaseWindow.dispatchEvent(XBaseWindow.java:1112)
	at sun.awt.X11.XFocusProxyWindow.dispatchEvent(XFocusProxyWindow.java:58)
	at sun.awt.X11.XBaseWindow.dispatchToWindow(XBaseWindow.java:1079)
	at sun.awt.X11.XToolkit.dispatchEvent(XToolkit.java:475)
	at sun.awt.X11.XToolkit.run(XToolkit.java:588)
	at sun.awt.X11.XToolkit.run(XToolkit.java:523)
	at java.lang.Thread.run(Thread.java:619)

=====================================================================================

This is reproduced only in this pit build ( 6u14 b03 pit build).   And it is reproduced only on solaris & linux. 



Testcase
-------
import java.awt.*;

public class LinkerWarningBug {
	public Frame frame=null;
	public Button b = null;

	LinkerWarningBug( ) {
		 try {
			Toolkit.getDefaultToolkit().getSystemEventQueue().invokeAndWait(new Runnable() {
				public void run() {
					frame = new Frame();
					frame.setLayout(new FlowLayout());
					frame.add(b = new Button("Press me"));
					b.addActionListener(new java.awt.event.ActionListener(){
						public void actionPerformed(java.awt.event.ActionEvent ae){
							System.out.println("You have pressed the button..!");
						}
					});
					frame.setSize(300,300);
					frame.setVisible(true);
				}
			});
		        } catch (Exception e) {
		            e.printStackTrace();
		            System.exit(1);
        }
	}

	public static void main(String []args){
		new LinkerWarningBug();
	}
}

                                    

Comments
EVALUATION

I've not put back the make/sun/xawt/mapfile-vers file, it seems.
                                     
2009-03-03



Hardware and Software, Engineered to Work Together