Skip to content
Snippets Groups Projects
  1. Sep 12, 2022
    • Michel Dänzer's avatar
      dix: Skip more code in SetRootClip for ROOT_CLIP_INPUT_ONLY · f778b56a
      Michel Dänzer authored
      Despite e957a2e5 ("dix: Add hybrid full-size/empty-clip mode to
      SetRootClip"), I was still seeing all X11 client windows flashing when
      the root window size changes with rootless Xwayland (e.g. due to
      hotplugging a monitor).
      
      Skipping this code for ROOT_CLIP_INPUT_ONLY fixes the issue for me.
      f778b56a
  2. Sep 11, 2022
  3. Sep 09, 2022
    • Peter Harris's avatar
      os: Restore buffer when writing to network · 2ab70ded
      Peter Harris authored and Alan Coopersmith's avatar Alan Coopersmith committed
      
      The commit 9bf46610 "os: Immediately
      queue initial WriteToClient" effectively disables buffering (of all
      writes, not just the "initial" write), since the OS's network buffers
      will usually be large enough to hold whatever replies we have sent.
      
      This does improve performance when drawing over a Unix socket (I measure
      approximtely 10%, not the ~5x mentioned in that commit message, probably
      due to the large changes in this area since that commit), but it
      decreases performance when drawing over a network due to the additional
      TCP packets. This decrease is small (~10%) in most cases, but if the two
      machines have mismatched Nagle / tcp_delay settings it can cause
      XGetWindowAttributes to take 200ms (because it's composed of two
      requests, the 2nd of which might wait for the ack which is delayed).
      
      Avoid network slowdowns by making the immediate flush conditional on
      who->local.
      
      Signed-off-by: default avatarPeter Harris <pharris@opentext.com>
      2ab70ded
  4. Sep 08, 2022
  5. Sep 07, 2022
    • Maya Rashish's avatar
      Simplify auto device configuration for choosing wsfb, fbdev · 399cf127
      Maya Rashish authored and Alan Coopersmith's avatar Alan Coopersmith committed
      I wanted to simplify the logic, and thought this is a good opportunity
      to eliminate local diffs.
      
      I don't want to list OSes without wsfb, because I understand that is a
      netbsd/openbsd driver, and always have it as a fallback for us.
      
      Additionally, I understand "fbdev" is linux-specific, so have the logic
      match this intent.
      399cf127
    • Michel Dänzer's avatar
      ci: Check that all expected piglit results are there · 421e066e
      Michel Dänzer authored
      Without these, the build jobs would spuriously pass if some of the
      expected piglit tests didn't run at all.
      
      v2:
      * Use local variables instead of starting their names with underscores
        (Peter Hutterer)
      421e066e
  6. Sep 02, 2022
  7. Aug 31, 2022
  8. Aug 29, 2022
  9. Aug 19, 2022
    • Michel Dänzer's avatar
      xwayland: Add break statements in pointer_handle_axis · f0b2eeaf
      Michel Dänzer authored
      Fixes accidentally taking the WL_POINTER_AXIS_HORIZONTAL_SCROLL case as
      well after the WL_POINTER_AXIS_VERTICAL_SCROLL case, which resulted in
      vertical wheel events triggering both vertical and horizontal scrolling.
      
      Fixes: e37eeb7a ("xwayland: Aggregate scroll axis events to fix kinetic scrolling")
      Closes: #1367
      f0b2eeaf
  10. Aug 11, 2022
    • Peter Hutterer's avatar
      xwayland: add support for the XWAYLAND extension · 2700bc60
      Peter Hutterer authored
      This extension exists to serve one purpose: reliably identifying
      Xwayland. Previous attempts at doing so included querying root window
      properties, output names or input device names. All these attempts are
      somewhat unreliable. Instead, let's use an extension - where that
      extension is present we have an Xwayland server.
      
      Clients should never need to do anything but check whether the extension
      exists through XQueryExtension or search through XListExtensions.
      
      This extension provides a single QueryVersion request only, and
      that is only to provide future compatibility if we ever need anything
      other than "this extension exists" functionality.
      
      xorg/proto/xorgproto!54
      
      
      
      Signed-off-by: default avatarPeter Hutterer <peter.hutterer@who-t.net>
      2700bc60
  11. Aug 09, 2022
  12. Aug 02, 2022
  13. Jul 27, 2022
    • Olivier Fourdan's avatar
      dix: Fix overzealous caching of ResourceClientBits() · 2efa6d65
      Olivier Fourdan authored
      Commit c7311654 cached the value of ResourceClientBits(), but that value
      depends on the `MaxClients` value set either from the command line or
      from the configuration file.
      
      For the latter, a call to ResourceClientBits() is issued before the
      configuration file is read, meaning that the cached value is from the
      default, not from the maximum number of clients set in the configuration
      file.
      
      That obviously causes all sort of issues, including memory corruption
      and crashes of the Xserver when reaching the default limit value.
      
      To avoid that issue, also keep the LimitClient value, and recompute the
      ilog2() value if that changes, as on startup when the value is set from
      the the xorg.conf ServerFlags section.
      
      v2: Drop the `cache == 0` test
          Rename cache vars
      
      Fixes: c7311654 - dix: cache ResourceClientBits() value
      Closes: #1310
      
      
      Signed-off-by: default avatarOlivier Fourdan <ofourdan@redhat.com>
      Reviewed-by: Adam Jackson's avatarAdam Jackson <ajax@redhat.com>
      2efa6d65
  14. Jul 26, 2022
    • Olivier Fourdan's avatar
      xwayland: Fix "-force-xrandr-emulation" · 24d7d93f
      Olivier Fourdan authored
      
      Commit 7cdcdfea introduced a new command line option
      "-force-xrandr-emulation", however it is missing from the
      ddxProcessArgument().
      
      As a result, trying to use that command option would result in a error:
      
      (EE) Unrecognized option: -force-xrandr-emulation
      
      Make sure "-force-xrandr-emulation" is accounted for in Xwayland's
      ddxProcessArgument().
      
      Signed-off-by: default avatarOlivier Fourdan <ofourdan@redhat.com>
      Fixes: 7cdcdfea - xwayland: Add -force-xrandr-emulation switch
      24d7d93f
  15. Jul 13, 2022
  16. Jul 12, 2022
    • Peter Hutterer's avatar
      xkb: add request length validation for XkbSetGeometry · 6907b6ea
      Peter Hutterer authored and Povilas Kanapickas's avatar Povilas Kanapickas committed
      
      No validation of the various fields on that report were done, so a
      malicious client could send a short request that claims it had N
      sections, or rows, or keys, and the server would process the request for
      N sections, running out of bounds of the actual request data.
      
      Fix this by adding size checks to ensure our data is valid.
      
      ZDI-CAN 16062, CVE-2022-2319.
      
      This vulnerability was discovered by:
      Jan-Niklas Sohn working with Trend Micro Zero Day Initiative
      
      Signed-off-by: default avatarPeter Hutterer <peter.hutterer@who-t.net>
      6907b6ea
    • Peter Hutterer's avatar
      xkb: swap XkbSetDeviceInfo and XkbSetDeviceInfoCheck · dd8caf39
      Peter Hutterer authored and Povilas Kanapickas's avatar Povilas Kanapickas committed
      
      XKB often uses a FooCheck and Foo function pair, the former is supposed
      to check all values in the request and error out on BadLength,
      BadValue, etc. The latter is then called once we're confident the values
      are good (they may still fail on an individual device, but that's a
      different topic).
      
      In the case of XkbSetDeviceInfo, those functions were incorrectly
      named, with XkbSetDeviceInfo ending up as the checker function and
      XkbSetDeviceInfoCheck as the setter function. As a result, the setter
      function was called before the checker function, accessing request
      data and modifying device state before we ensured that the data is
      valid.
      
      In particular, the setter function relied on values being already
      byte-swapped. This in turn could lead to potential OOB memory access.
      
      Fix this by correctly naming the functions and moving the length checks
      over to the checker function. These were added in 87c64fc5 to the
      wrong function, probably due to the incorrect naming.
      
      Fixes ZDI-CAN 16070, CVE-2022-2320.
      
      This vulnerability was discovered by:
      Jan-Niklas Sohn working with Trend Micro Zero Day Initiative
      
      Introduced in c06e27b2
      
      Signed-off-by: default avatarPeter Hutterer <peter.hutterer@who-t.net>
      dd8caf39
  17. Jul 08, 2022
  18. Jul 04, 2022
  19. Jul 02, 2022
  20. Jul 01, 2022
Loading