shell-window-tracker: Detect invalid PID values of 0
MetaWindows get_pid() API changed to use the client PID, which also works for Wayland clients instead of only X11 clients now. This API returns 0 instead of -1 for invalid PIDs, so update our check according to that. https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1184
This commit is contained in:
parent
e8f5a842b1
commit
4aee87a31b
@ -343,7 +343,7 @@ get_app_from_window_pid (ShellWindowTracker *tracker,
|
||||
|
||||
pid = meta_window_get_pid (window);
|
||||
|
||||
if (pid == -1)
|
||||
if (pid < 1)
|
||||
return NULL;
|
||||
|
||||
result = shell_window_tracker_get_app_from_pid (tracker, pid);
|
||||
|
Loading…
Reference in New Issue
Block a user