fcitx / xcb-imdkit

input method development support for xcb
38 stars 8 forks source link

wezterm calls `_xcb_xim_open` repeatedly creating an enormous number of windows #16

Open yshui opened 2 months ago

yshui commented 2 months ago

Discovered in yshui/picom#1289

wezterm calls _xcb_xim_open, because it does not have an IC. _xcb_xim_open calls wezterm's open_callback, which calls xcb_xim_create_ic. However the callback passed to xcb_xim_create_ic is never called.

The reason for that is because in _xcb_xim_process_queue, im->current is not NULL, presumably because a previous request is not completed yet. as to what happened to that request, i don't know.

wezterm is using an older version of xcb-imdkit (1.0.3), don't know if a problem like this is fixed or not.

wengxt commented 2 months ago

I feel it is a bug about how they use the api.

xcb_xim_open should only be called once through the app life time, until a xcb_xim_close is called.