<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Weston confuses SIGUSR1 signals from Xwayland and VT switch"
href="https://bugs.freedesktop.org/show_bug.cgi?id=87322">87322</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Weston confuses SIGUSR1 signals from Xwayland and VT switch
</td>
</tr>
<tr>
<th>Product</th>
<td>Wayland
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>All
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux (All)
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Component</th>
<td>weston
</td>
</tr>
<tr>
<th>Assignee</th>
<td>wayland-bugs@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>ppaalanen@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>jjardon@gnome.org
</td>
</tr></table>
<p>
<div>
<pre>Javier complained the other day, that Weston freezes on starting any X11 app
via Xwayland. I can't recall the details. The Weston log was very interesting,
though: it showed that as soon as XWM initializes, Weston thinks it's leaving
the VT.
Looking at the code, I'm surprised it hasn't blown up for anyone else yet.
Weston routinely uses SIGUSR1 for VT-switching signalling. Weston-launch
watches SIGUSR1, that is not a problem. However, when Weston is started without
weston-launch, Weston itself may be watching for SIGUSR1:
- src/launcher-util.c (Weston as root, without logind?)
- src/logind-util.c (non-root with logind support?)
Those two seem mutually exclusive, but there is a third one:
- xwayland/launcher.c (for Xwayland server start-up notification)
I guess what happens in Javier's case, is that when Xwayland server starts, it
sends SIGUSR1 to Weston, which then runs all SIGUSR1 handlers in some arbitary
order: VT switch and XWM init. This leads to Weston thinking it's no longer
current, likely refusing all input, and you have a frozen VT.
Seems like something should be moved to another signal number.
(And why does logind-util.c call signalfd() manually instead of
wl_event_loop_add_signal()?)</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>