[Xwayland 22.1] Backport a few more fixes

Merged Olivier Fourdan requested to merge ofourdan/xserver:xwayland-22.1-backports into xwayland-22.1

See commit list for details.

Merge request reports