Linux: Don't free already freed XIC and XIM instances in LinuxKeyboard
This commit is contained in:
parent
84600dffdb
commit
552b7ca3fc
|
@ -144,8 +144,10 @@ final class LinuxKeyboard {
|
|||
private static native ByteBuffer allocateComposeStatus();
|
||||
|
||||
public void destroy() {
|
||||
destroyIC(xic);
|
||||
closeIM(xim);
|
||||
if (xic != 0)
|
||||
destroyIC(xic);
|
||||
if (xim != 0)
|
||||
closeIM(xim);
|
||||
}
|
||||
private static native void destroyIC(long xic);
|
||||
private static native void closeIM(long xim);
|
||||
|
|
Loading…
Reference in New Issue