https://bugs.kde.org/show_bug.cgi?id=522899

--- Comment #2 from Wehrwolfmann <[email protected]> ---
I ran into the same symptom from a different direction, and it may widen this
report:
X11 clients hang on connect() even when Xwayland is installed and actually
running.

My case was a KWin built from master (e1a7347b) into a private prefix, started
as a
nested compositor. Xwayland came up fine — I could see the process and its
xkbcomp
output — but xdpyinfo, and every other X client, blocked forever on the socket.

The reason is the same pattern Kevin describes, in a second place. In
Xwayland::runXWaylandStartupScripts() (src/xwayland/xwayland.cpp:586) the
server is
only declared ready once readyGuard is destroyed, and that guard is captured by
lambdas connected to QProcess::finished alone (line 607). The list of scripts
always
includes $LIBEXEC_DIR/plasma-setup-xwayland. That file ships with
plasma-workspace,
so a KWin installed into its own prefix does not have it, QProcess fails to
start,
finished() is never emitted, the guard is never released, and registerReady()
is
never called. Xwayland keeps the clients waiting from then on.

Dropping a stub at that path (#!/bin/sh, exit 0) makes everything work
immediately,
which I think confirms the chain.

What made this expensive to debug is that there is no diagnostic at all: no
warning
that a startup script could not be run, and no timeout on becoming ready.
Listening
to QProcess::errorOccurred next to finished() in both places would cover the
failure,
and a warning would make it self-explanatory.

Happy to test a patch on that setup.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to