Bug 92384

Summary: Bogus use of wl_surface scaling leads to compositor crash
Product: Wayland Reporter: Link Mauve <bugs>
Component: westonAssignee: Wayland bug list <wayland-bugs>
Status: RESOLVED MOVED QA Contact:
Severity: critical    
Priority: medium    
Version: unspecified   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments: patch for glfw making it reproduce the crash
gdb trace of the segfault

Description Link Mauve 2015-10-10 13:08:40 UTC
Created attachment 118797 [details]
patch for glfw making it reproduce the crash

This happens on both Weston 1.9.0 and latest git as of the 10th of October.

In the attached patch against GLFW, wl_egl_window_resize is incorrectly called in maybeChangeScale(), which leads to a client lockup and potentially a compositor crash (I haven’t been able to reproduce it each time, but in a good 50%).

Steps to reproduce:
1. Clone, patch and install GLFW master (https://github.com/glfw/glfw)
2. Get Citra (http://citra-emu.org/) or probably any other GLFW program
3. Start Weston with two mixed-scaling outputs
4. Run the GLFW program, and move it between the different outputs.
Comment 1 Link Mauve 2015-10-10 13:09:18 UTC
Created attachment 118798 [details]
gdb trace of the segfault
Comment 2 Daniel Stone 2018-06-04 09:04:23 UTC
Hm, I wonder if the problem here is that the client gets killed by a protocol error; then by the time the xdg_toplevel ping has timed out, the resource is no longer there so we dereference garbage.

Can you still reproduce this, and if so, could you please get a Valgrind trace?
Comment 3 GitLab Migration User 2018-06-08 23:54:09 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/wayland/weston/issues/69.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.