]> git.mdlowis.com Git - proto/labwc.git/commit
Fix pid lookup for the Kill action
authorConsolatis <35009135+Consolatis@users.noreply.github.com>
Mon, 22 Apr 2024 15:43:46 +0000 (17:43 +0200)
committerJohan Malm <johanmalm@users.noreply.github.com>
Mon, 22 Apr 2024 18:11:57 +0000 (19:11 +0100)
commit3f10857496e1027af3740d374b749fa5d58c0010
tree9db6b578050748894a8d0f90b3f7e59c66efaf2e
parenta109e6e3e888eea02b3126d9c20aee23016223e4
Fix pid lookup for the Kill action

Before this patch, labwc would happily kill itself when the user
called the `Kill` action when any xwayland view had focus.

The reason this happened was that wlroots creates the xwayland
wayland client via socketpair() and thus a lookup of the pid
of the socket connection would return the pid of labwc itself.

This patch fixes that by implementing different pid lookup
mechanisms based on the view implementation backend.

Fixes: #1739
include/view.h
src/action.c
src/xdg.c
src/xwayland.c