Skip to content

Commit

Permalink
xwayland: don't destroy server client
Browse files Browse the repository at this point in the history
this potentially leaks, but avoids a UAF

ref #6323
  • Loading branch information
vaxerski committed Jun 3, 2024
1 parent 0ac0f32 commit 5517cc5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/xwayland/Server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,9 @@ void CXWaylandServer::die() {
if (xwmFDs[1])
close(xwmFDs[1]);

if (xwaylandClient)
wl_client_destroy(xwaylandClient);
// possible crash. Better to leak a bit.
//if (xwaylandClient)
// wl_client_destroy(xwaylandClient);

xwaylandClient = nullptr;
waylandFDs = {-1, -1};
Expand Down

0 comments on commit 5517cc5

Please sign in to comment.