[Wayland-bugs] [Bug 95337] XWayland crashes during startup if output data is received

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu May 12 07:54:08 UTC 2016


https://bugs.freedesktop.org/show_bug.cgi?id=95337

--- Comment #4 from Olivier Fourdan <fourdan at xfce.org> ---
(In reply to Jonas Ã…dahl from comment #2)
> [...]
> I think that if we don't roundtrip here, we might end up in a situation
> where various places expects to be able to know things about wl_seat's etc,
> that'd now start to crash if we loose the race against the wl_seat global
> being discovered.

I don't experience any crash with this patch applied, neither with mutter which
spawns Xwayland at startup as it (still) relies on X, i.e. very early, nor with
weston which spawns it when needed (ie with all outputs and seats set-up).

> AFAICS InitInput() is done after InitOutput() which is where xwl_screen_init
> and the first roundtrips are done.

You're right, of course, but the problem is not much xwl_screen_init() but the
X ConnectionInfo (as reported in comment #0) that gets initialized after
InitInput is called in dix.

It goes like this:

  xwl_screen_init()
  InitInput()
  ConnectionInfo initialized

So if the roundtrip in InitInput() trigger something that needs to use the X
connection (as with RR in the backtrace), it will crash.

Meanwhile, ajax picked up the patch from the ML and pushed it, so it's landed
in master (I did send the patch to the devel ML in parallel as this is where
patches get discussed for xorg rather than bugzilla).

But I am not convinced this patch would cause more bad that good, initializing
xwl_screen->expecting_event to 0 twice at two different places doesn't sound
right and doing the rountrip before X connection is likely to cause breakage as
well, as seen in comment #0.

Let's keep that bug opened and see if we get some more feedback (either here or
on the xorg-devel ML), meanwhile please test master with different compositors
and use cases and let's see if this a real problem.

(In reply to Pekka Paalanen from comment #3)
> Mind, wl_seats can come and go dynamically, and it is not guaranteed to have
> at least one at all times. So, working without any seat would sound like a
> good idea to me.
> 
> The same goes for outputs, and will likely be testable on Weston once
> Armin's GSoC project is near finishing.

Yes, probably, but I reckon outputs are a different issue than this particular
crash.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/wayland-bugs/attachments/20160512/347526b8/attachment.html>


More information about the wayland-bugs mailing list