<i18n dev> <AWT Dev> Request for review: Crash on XIM server restart

Artem Ananiev artem.ananiev at oracle.com
Thu Sep 23 02:33:21 PDT 2010

Hi, Omair,

I'm not an i18n expert, just would like to understand the problem and 
the fix.

Could you provide the stack trace of the crash, please?

As I understand, the reason of calling getX11InputMethodData is that you 
need to destroy "pX11IMData" and set the corresponding field in Java to 
null, right?



On 9/16/2010 11:58 PM, Omair Majid wrote:
> Hi,
> While looking at the bug filed at
> https://bugzilla.redhat.com/show_bug.cgi?id=572147, I noticed that Java
> applications crash if IBus (an X input server) is restarted.
> The webrev is at
> http://cr.openjdk.java.net/~omajid/webrevs/crash-on-xim-server-restart/webrev.00/
> The code in awt_InputMethod.c guards against the XIM server going away,
> but does not guard against it appearing again. When the XIM server is
> restarted, the X server can send async requests to call OpenXIMCallback
> in Java automatically:
> (gdb) bt
> #0 OpenXIMCallback (display=<value optimized out>,
> client_data=<value optimized out>, call_data=<value optimized out>)
> at ../../../src/solaris/native/sun/awt/awt_InputMethod.c:1464
> #1 0x00000036b406dc4f in _XimFilterPropertyNotify (display=0x7f503c0df300,
> window=<value optimized out>, event=<value optimized out>,
> client_data=<value optimized out>) at imInsClbk.c:126
> #2 0x00007f4ff24f0f3f in Java_sun_awt_X11_XlibWrapper_XFilterEvent (
> env=<value optimized out>, clazz=<value optimized out>,
> ptr=<value optimized out>, window=<value optimized out>)
> at ../../../src/solaris/native/sun/xawt/XlibWrapper.c:486
> #3 0x00007f5039010f50 in ?? ()
> #4 0x00007f5039005953 in ?? ()
> #5 0x0000000000000000 in ?? ()
> This causes the X11im pointer to get initialized and the checks in
> getX11InputMethodData are escaped. The patch simply makes sure that the
> checks are not escaped by calling getX11InputMethodData in
> DestroyXIMCallback.
> Any thoughts or comments?
> Cheers,
> Omair

More information about the i18n-dev mailing list