1. 11 Jun, 2019 3 commits
  2. 18 Apr, 2019 4 commits
  3. 20 Feb, 2019 1 commit
  4. 16 Feb, 2019 3 commits
    • Sergey Bugaev's avatar
      desktop-shell: don't crash if a surface disappears while grabbed · 14ef2012
      Sergey Bugaev authored
      A surface can get destroyed while a shell grab is active, which can
      for example happen if the command running in weston-terminal exits.
      
      When a surface gets destroyed, grab->shsurf is reset to NULL by
      destroy_shell_grab_shsurf(), but otherwise the grab remains active and
      its callbacks continue to be called. Thus, dereferencing grab->shsurf
      in a callback without checking it for NULL first can lead to undefined
      behavior, including crashes.
      
      Several functions were already properly checking grab->shsurf for NULL,
      move_grab_motion() being one example. Others, however, were not, which
      is what this commit fixes.
      
      Related to wayland/weston#192Signed-off-by: Sergey Bugaev's avatarSergey Bugaev <bugaevc@gmail.com>
      14ef2012
    • myfreeweb's avatar
      desktop-shell: remove surface destroy listener when focus state is destroyed · 15d3d300
      myfreeweb authored
      Changing the focused surface did remove the surface_destroy_listener from the wl_signal list,
      but destroying the focus state did not. As a result, sometimes the same listener would be added
      to two surfaces, which would join their wl_signal lists together, which would cause infinite
      loops and use-after-frees when closing desktop surfaces.
      15d3d300
    • myfreeweb's avatar
      desktop-shell: fix resize grab related crash · ec3f779a
      myfreeweb authored
      This crash was happening when *releasing* a pointer button on a window
      that was being resized and got destroyed during the grab.
      
      [@daniels: Cosmetic fixes; apply same fix to grab cancel.]
      ec3f779a
  5. 06 Feb, 2019 1 commit
    • Pekka Paalanen's avatar
      desktop-shell: use weston_compositor_exit · 052032d7
      Pekka Paalanen authored
      Use the proper weston_compositor_exit API instead of wl_display_terminate() to
      allow the compositor main to prepare for exit, and most importantly to set the
      exit error code as appropriate.
      
      I have some brokenness in my test suite running, and weston-desktop-shell was
      crashing at start, yet the tests did not notice. With this patch, the tests
      where the helper crashes are properly marked as failed.
      Signed-off-by: Pekka Paalanen's avatarPekka Paalanen <pekka.paalanen@collabora.com>
      052032d7
  6. 31 Jan, 2019 1 commit
  7. 18 Dec, 2018 1 commit
  8. 09 Dec, 2018 1 commit
    • Daniel Stone's avatar
      Add Meson build system · 8011b0fa
      Daniel Stone authored
      Meson is a build system, currently implemented in Python, with multiple
      output backends, including Ninja and Make. The build file syntax is
      clean and easy to read unlike autotools. In practise, configuring and
      building with Meson and Ninja has been observed to be much faster than
      with autotools. Also cross-building support is excellent.
      
      More information at http://mesonbuild.com
      
      Since moving to Meson requires some changes from users in any case, we
      took this opportunity to revamp build options. Most of the build options
      still exist, some have changed names or more, and a few have been
      dropped. The option to choose the Cairo flavour is not implemented since
      for the longest time the Cairo image backend has been the only
      recommended one.
      
      This Meson build should be fully functional and it installs everything
      an all-enabled autotools build does. Installed pkg-config files have
      some minor differences that should be insignificant. Building of some
      developer documentation that was never installed with autotools is
      missing.
      
      It is expected that the autotools build system will be removed soon
      after the next Weston release.
      Signed-off-by: Daniel Stone's avatarDaniel Stone <daniels@collabora.com>
      Co-authored-by: Pekka Paalanen's avatarPekka Paalanen <pq@iki.fi>
      Signed-off-by: Pekka Paalanen's avatarPekka Paalanen <pq@iki.fi>
      8011b0fa
  9. 08 Aug, 2018 1 commit
  10. 09 Jul, 2018 1 commit
    • Daniel Stone's avatar
      helpers: Move static_assert definition to shared · 11f91bbd
      Daniel Stone authored
      Collect the fallback definitions of static_assert() from desktop-shell
      and the test shell, and move them to helpers.h. This allows code
      throughout the tree to use static_assert() for build-time assertions,
      where it is supported by the compiler.
      
      As GCC goes out of its way to only add static_assert() when C11 has been
      explicitly requested - which we don't do - make sure to use the more
      widely available _Static_assert() if that is provided.
      
      This will be used in future patches to ensure two array lengths don't go
      out of sync.
      Signed-off-by: Daniel Stone's avatarDaniel Stone <daniels@collabora.com>
      Reviewed-by: Pekka Paalanen's avatarPekka Paalanen <pekka.paalanen@collabora.co.uk>
      11f91bbd
  11. 20 Jun, 2018 1 commit
    • Daniel Stone's avatar
      tests: Don't rely on build directory layout · e03c111e
      Daniel Stone authored
      Rather than having a hardcoded dependency on the build-directory layout,
      use an explicit module-map environment variable, which rewrites requests
      for modules and helper/libexec binaries to specific paths.
      
      Pekka: This will help with migration to Meson where setting up the paths
      according to autotools would be painful and unnecessary.
      
      Emre: This should also help setting up the test suite after a
      cross-compile.
      
      Pekka: A caveat here is that this patch makes it slightly easier to load
      external backends by abusing the module map. External backends are
      specifically not supported in libweston.
      Signed-off-by: Daniel Stone's avatarDaniel Stone <daniels@collabora.com>
      
      v2:
      
      Fixed ivi_layout-test-plugin.c:wet_module_init().
      Do not change the lookup name of ivi-layout.ivi.
      
      Improved documentation of weston_module_path_from_env() and made it cope
      with map strings that a) do not end with a semicolon, and b) have
      multiple consecutive semicolons.
      
      Let WESTON_MODULE_MAP be printed into the test log so that it is easier
      to run tests manually.
      Reviewed-by: Daniel Stone's avatarDaniel Stone <daniels@collabora.com>
      Reviewed-by: eucan's avatarEmre Ucan <eucan@de.adit-jv.com>
      
      Suggested by Emil: Use a variable for strlen(name).
      Signed-off-by: Pekka Paalanen's avatarPekka Paalanen <pekka.paalanen@collabora.co.uk>
      Reviewed-by: default avatarEmil Velikov <emil.velikov@collabora.com>
      e03c111e
  12. 24 May, 2018 4 commits
  13. 22 May, 2018 1 commit
  14. 21 May, 2018 1 commit
  15. 18 May, 2018 1 commit
  16. 10 Apr, 2018 1 commit
  17. 14 Feb, 2018 1 commit
  18. 12 Feb, 2018 2 commits
    • Pekka Paalanen's avatar
      desktop-shell: handle redundant panels · 1a0239e4
      Pekka Paalanen authored
      If for some reason the helper client weston-desktop-shell would create
      more than one panel surface for the same weston_output, this code would
      corrupt the surface destroy listener list by adding a link already in
      one list into another list.
      
      Instead, do not store the new, redundant panel surface and do not
      subscribe to its destruction. Also, tell the helper that the surface is
      redundant by configuring it with a 0x0 size, so that we don't waste
      memory on a panel that is never used.
      
      (Clone mode is a valid reason why weston-desktop-shell could do that.)
      Signed-off-by: Pekka Paalanen's avatarPekka Paalanen <pekka.paalanen@collabora.co.uk>
      Reviewed-by: Daniel Stone's avatarDaniel Stone <daniels@collabora.com>
      1a0239e4
    • Pekka Paalanen's avatar
      desktop-shell: handle redundant backgrounds · ff5e88d2
      Pekka Paalanen authored
      If for some reason the helper client weston-desktop-shell would create
      more than one background surface for the same weston_output, this code
      would corrupt the surface destroy listener list by adding a link already
      in one list into another list.
      
      Instead, do not store the new, redundant background surface and do not
      subscribe to its destruction. Also, tell the helper that the surface is
      redundant by configuring it with a 0x0 size, so that we don't waste
      memory on a background that is never used.
      
      (Clone mode is a valid reason why weston-desktop-shell could do that.)
      Signed-off-by: Pekka Paalanen's avatarPekka Paalanen <pekka.paalanen@collabora.co.uk>
      Reviewed-by: Daniel Stone's avatarDaniel Stone <daniels@collabora.com>
      ff5e88d2
  19. 09 Feb, 2018 1 commit
  20. 31 Jan, 2018 1 commit
  21. 04 Dec, 2017 2 commits
  22. 27 Nov, 2017 7 commits