mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-11-22 12:55:58 +01:00
Merge pull request #749 from psychon/fix_x11_use_after_free
Fix use-after-free in x11 backend during shutdown
This commit is contained in:
commit
bcb74c2c78
1 changed files with 0 additions and 4 deletions
|
@ -326,9 +326,6 @@ static void wlr_x11_backend_destroy(struct wlr_backend *backend) {
|
||||||
wl_event_source_remove(x11->frame_timer);
|
wl_event_source_remove(x11->frame_timer);
|
||||||
wlr_egl_finish(&x11->egl);
|
wlr_egl_finish(&x11->egl);
|
||||||
|
|
||||||
if (x11->xcb_conn) {
|
|
||||||
xcb_disconnect(x11->xcb_conn);
|
|
||||||
}
|
|
||||||
if (x11->xlib_conn) {
|
if (x11->xlib_conn) {
|
||||||
XCloseDisplay(x11->xlib_conn);
|
XCloseDisplay(x11->xlib_conn);
|
||||||
}
|
}
|
||||||
|
@ -428,7 +425,6 @@ struct wlr_backend *wlr_x11_backend_create(struct wl_display *display,
|
||||||
error_event:
|
error_event:
|
||||||
wl_event_source_remove(x11->event_source);
|
wl_event_source_remove(x11->event_source);
|
||||||
error_x11:
|
error_x11:
|
||||||
xcb_disconnect(x11->xcb_conn);
|
|
||||||
XCloseDisplay(x11->xlib_conn);
|
XCloseDisplay(x11->xlib_conn);
|
||||||
free(x11);
|
free(x11);
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
Loading…
Reference in a new issue