mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2025-11-09 13:29:54 -05:00
opt: optimize clean input_method data to avoid crash when exit maomao
This commit is contained in:
parent
73f19d38af
commit
6ce7460161
1 changed files with 2 additions and 2 deletions
|
|
@ -2397,8 +2397,6 @@ void cleanup(void) {
|
||||||
xwayland = NULL;
|
xwayland = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
input_method_relay_finish(input_method_relay);
|
|
||||||
|
|
||||||
wl_display_destroy_clients(dpy);
|
wl_display_destroy_clients(dpy);
|
||||||
if (child_pid > 0) {
|
if (child_pid > 0) {
|
||||||
kill(-child_pid, SIGTERM);
|
kill(-child_pid, SIGTERM);
|
||||||
|
|
@ -2408,6 +2406,8 @@ void cleanup(void) {
|
||||||
|
|
||||||
destroykeyboardgroup(&kb_group->destroy, NULL);
|
destroykeyboardgroup(&kb_group->destroy, NULL);
|
||||||
|
|
||||||
|
input_method_relay_finish(input_method_relay);
|
||||||
|
|
||||||
/* If it's not destroyed manually it will cause a use-after-free of wlr_seat.
|
/* If it's not destroyed manually it will cause a use-after-free of wlr_seat.
|
||||||
* Destroy it until it's fixed in the wlroots side */
|
* Destroy it until it's fixed in the wlroots side */
|
||||||
wlr_backend_destroy(backend);
|
wlr_backend_destroy(backend);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue