- Aug 27, 2018
-
-
Keith Packard authored
Output scaling: * Changes to mivaltree to reset window clip to owner window size instead of server window size when compositing * Allocate owner window size pixmap for composite pixmap * Paint scaled image for automatic compositing * Report owner window size in events to the window owner. * Scale exposure damage in compSetRedirectBorderClip from current size to owner size to make sure the correct parts of the window are repainted. Input scaling: * Change miSpriteTrace to scale cursor coordinates when transiting an owner-sized window. Do all computations in double to handle multiple such transitions without losing bits * Add ScaleRootCoordinate in events.c. This function takes a window and a root x/y and walks up the tree scaling each time there is an owner size set. * Use ScaleRootCoordinate in FixUpEventFromWindow. * Wrap event delivery in DeliverEvent in new SaveEventRootCoord/RestoreEventRootCoord functions so that different windows receiving the same event will all receive the correct coordinates. Composite events: * Deliver CompositePixmapNotify events from compSetPixmapVisitWindow so that applications will be notified each time the pixmap changes. * Deliver CompositeOwnerWindowSizeNotify events when owner window size is set. Signed-off-by:
Keith Packard <keithp@keithp.com>
-
- Aug 08, 2018
-
-
Not sure what if anything calls XSetDeviceModifierMapping() but this would've failed all the time. check_modmap_change() returns Success but we were treating it like a boolean. Fix this. Reported-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by:
Keith Packard <keithp@keithp.com>
-
- May 08, 2018
-
-
Signed-off-by:
Eric Anholt <eric@anholt.net> Reviewed-by:
Adam Jackson <ajax@redhat.com>
-
- Apr 24, 2018
-
-
Adam Jackson authored
GLX registers an extension before we know if there are any screens that can actually do it. It's inconvenient to shrink the extension list, so instead allow the extension to simply zero out its base opcode to indicate that it needed to panic and disable itself. Signed-off-by:
Adam Jackson <ajax@redhat.com>
-
Adam Jackson authored
Signed-off-by:
Adam Jackson <ajax@redhat.com>
-
- Apr 10, 2018
-
-
Focus events are useless when 'from' and 'to' are the same. But when this is the result of a (Un)GrabKeyboard request, we should always send them, including when the window manager had previously used XSetInputFocus to specify the focus on a window which happens to be now taking a grab. This is notably needed for window manager using XI to always get keyboard events even during grabs, so they can determine exactly when grabbing is active. Signed-off-by:
Samuel Thibault <samuel.thibault@ens-lyon.org> Reviewed-by:
Peter Hutterer <peter.hutterer@who-t.net>
-
- Apr 05, 2018
-
-
Adam Jackson authored
../dix/getevents.c: In function ‘transformAbsolute’: ../dix/getevents.c:1195:28: warning: ‘oy’ may be used uninitialized in this function [-Wmaybe-uninitialized] struct pixman_f_vector p = {.v = {*x, *y, 1} }; ^ ../dix/getevents.c:1234:22: note: ‘oy’ was declared here double x, y, ox, oy; ^~ This one is truly special. Even though both ox and oy are set and read along the same paths, only oy is marked for this warning! Initializing just oy = 0.0 fixes it entirely, but let's not make a weird thing weirder. Signed-off-by:
Adam Jackson <ajax@redhat.com> Acked-by:
Keith Packard <keithp@keithp.com>
-
- Mar 27, 2018
-
-
Adam Jackson authored
One fix the constructed path, two actually install it. Signed-off-by:
Adam Jackson <ajax@redhat.com> Reviewed-by:
Keith Packard <keithp@keithp.com>
-
- Feb 27, 2018
-
-
Noticed while skimming for the typo'd version ;-) Signed-off-by:
Emil Velikov <emil.velikov@collabora.com> Reviewed-by:
Adam Jackson <ajax@redhat.com>
-
- Dec 06, 2017
-
-
PtrCtrl really makes sense for relative pointing device only, absolute devices such as touch devices do not have any PtrCtrl set. In some cases, if the client issues a XGetPointerControl() immediatlely after a ChangeMasterDeviceClasses() copied the touch device to the VCP, a NULL pointer dereference will occur leading to a crash of Xwayland. Check whether the PtrCtrl is not NULL in ProcGetPointerControl() and return the default control values otherwise, to avoid the NULL pointer dereference. Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1519533 Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Olivier Fourdan <ofourdan@redhat.com>
-
- Nov 06, 2017
-
-
Adam Jackson authored
Your libc has ffs, I promise. Signed-off-by:
Adam Jackson <ajax@redhat.com> Reviewed-by:
Alan Coopersmith <alan.coopersmith@oracle.com>
-
Reviewed-by:
Adam Jackson <ajax@redhat.com>
-
- Oct 30, 2017
-
-
Roundhouse kick replacing the various (sizeof(foo)/sizeof(foo[0])) with the ARRAY_SIZE macro from dix.h when possible. A semantic patch for coccinelle has been used first. Additionally, a few macros have been inlined as they had only one or two users. Signed-off-by:
Daniel Martin <consume.noise@gmail.com> Reviewed-by:
Adam Jackson <ajax@redhat.com>
-
- Oct 10, 2017
-
-
Reviewed-by:
Julien Cristau <jcristau@debian.org> Signed-off-by:
Nathan Kidd <nkidd@opentext.com> Signed-off-by:
Julien Cristau <jcristau@debian.org>
-
- Aug 15, 2017
-
-
This allows making the master screen's pixmap_dirty_list entries explicitly reflect that we're now tracking the root window instead of the screen pixmap, in order to allow Present page flipping on master outputs while there are active slave outputs. Define HAS_DIRTYTRACKING_DRAWABLE_SRC for drivers to check, but leave HAS_DIRTYTRACKING_ROTATION defined as well to make things slightly easier for drivers. Reviewed-by:
Adam Jackson <ajax@redhat.com>
-
- Jul 31, 2017
-
-
gmake[2]: Entering directory '/path/to/xserver/dix' /usr/sbin/dtrace -G -C -o dtrace-dix.o -s ../dix/Xserver.d .libs/atom.o ... dtrace: failed to compile script ../dix/Xserver.d: line 26: useless declaration gmake[2]: *** [Makefile:1007: dtrace-dix.o] Error 1 Signed-off-by:
Jan Beich <jbeich@FreeBSD.org> Reviewed-by:
Alan Coopersmith <alan.coopersmith@oracle.com>
-
- Jun 20, 2017
-
-
Adam Jackson authored
This appears to be essentially unused. The only known client-side library for the SELinux extension is xcb, which does not look for the name "Flask". The "SGI-GLX" alias for GLX appears to be a bit of superstition at this point, NVIDIA's driver does not expose it and Mesa does not check for it. Signed-off-by:
Adam Jackson <ajax@redhat.com> Acked-by:
Keith Packard <keithp@keithp.com>
-
- Jun 19, 2017
-
-
The SendEvent request holds xEvent which is exactly 32 bytes long, no more, no less. Both ProcSendEvent and SProcSendEvent verify that the received data exactly match the request size. However nothing stops the client from passing in event with xEvent::type = GenericEvent and any value of xGenericEvent::length. In the case of ProcSendEvent, the event will be eventually passed to WriteEventsToClient which will see that it is Generic event and copy the arbitrary length from the receive buffer (and possibly past it) and send it to the other client. This allows clients to copy unitialized heap memory out of X server or to crash it. In case of SProcSendEvent, it will attempt to swap the incoming event by calling a swapping function from the EventSwapVector array. The swapped event is written to target buffer, which in this case is local xEvent variable. The xEvent variable is 32 bytes long, but the swapping functions for GenericEvents expect that the target buffer has size matching the size of the source GenericEvent. This allows clients to cause stack buffer overflows. Signed-off-by:
Michal Srb <msrb@suse.com> Reviewed-by:
Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by:
Peter Hutterer <peter.hutterer@who-t.net>
-
- Jun 07, 2017
-
-
If the root window borderClip region is null, the PointInWindowIsVisible() check fails if pointer warping is attempted on the root window, making the warping operation bail out early. Assume coordinates always lay inside the root window for this case, the actual position will be clamped later within screen coordinates anyway. Signed-off-by:
Carlos Garnacho <carlosg@gnome.org> Acked-by:
Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by:
Peter Hutterer <peter.hutterer@who-t.net>
-
- May 12, 2017
-
-
Keith Packard authored
Delay removing the client from these two queues until all potential I/O has completed in case we mark the client as ready for reading or with pending output during the close operation. Bugzilla: https://bugs.freedesktop.org/100957 Signed-off-by:
Keith Packard <keithp@keithp.com> Tested-by:
Nick Sarnie <commendsarnex@gmail.com> Reviewed-by:
Michel Dänzer <michel.daenzer@amd.com>
-
- Apr 26, 2017
-
-
Emma Anholt authored
This is a work in progress that builds Xvfb, Xephyr, Xwayland, Xnest, and Xdmx so far. The outline of Xquartz/Xwin support is in tree, but hasn't been built yet. The unit tests are also not done. The intent is to build this as a complete replacement for the autotools system, then eventually replace autotools. meson is faster to generate the build, faster to run the bulid, shorter to write the build files in, and less error-prone than autotools. v2: Fix indentation nits, move version declaration to project(), use existing meson_options for version-config.h's vendor name/web. Signed-off-by:
Eric Anholt <eric@anholt.net> Acked-by:
Keith Packard <keithp@keithp.com> Reviewed-by:
Peter Hutterer <peter.hutterer@who-t.net>
-
Found when the meson conversion set the symbol to defined, instead of defined to 1. Reviewed-by:
Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by:
Keith Packard <keithp@keithp.com> Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Eric Anholt <eric@anholt.net>
-
- Mar 27, 2017
-
-
Adam Jackson authored
Most of this is a legacy of the old "extmod" design where you could load _some_ extensions dynamically but only if the server had been built with support for them in the first place. Note that since we now only initialize the DPMS extension if at least one screen supports it, we no longer need DPMSCapableFlag: if it would be false, we would never read its value. Signed-off-by:
Adam Jackson <ajax@redhat.com> Reviewed-by:
Eric Anholt <eric@anholt.net>
-
- Mar 21, 2017
-
-
Adam Jackson authored
None of this is actually wired up to anything, so we can also remove the devPrivates from the DamageRec. The DamageExtRec is what would need devPrivates for selinux labeling, in principle. Signed-off-by:
Adam Jackson <ajax@redhat.com> Reviewed-by:
Eric Anholt <eric@anholt.net>
-
- Mar 01, 2017
-
-
Adam Jackson authored
This touches everything that ends up in the Xorg binary; the big missing part is GLX since that's all generated code. Cuts about 14k from the binary on amd64. Signed-off-by:
Adam Jackson <ajax@redhat.com> Reviewed-by:
Eric Anholt <eric@anholt.net>
-
- Feb 23, 2017
-
-
Adam Jackson authored
This will be used by in-server features that need to react to property changes. The first one will be _XWAYLAND_ALLOW_COMMITS. Signed-off-by:
Adam Jackson <ajax@redhat.com> [Pekka: add commit message body] Signed-off-by:
Pekka Paalanen <pekka.paalanen@collabora.co.uk>
-
Adam Jackson authored
Instead of just the atom. No functional change. Signed-off-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Pekka Paalanen <pekka.paalanen@collabora.co.uk>
-
- Feb 16, 2017
-
-
The root window, and by extension any damage records referencing it, may be destroyed before shared pixmaps referencing it, which resulted in use-after-free / double-free in PixmapStopDirtyTracking. Fixes: b5b29289 ("prime: Sync shared pixmap from root window instead of screen pixmap") Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Michel Dänzer <michel.daenzer@amd.com>
-
- Feb 08, 2017
-
-
The screen pixmap doesn't receive updates while there's a Present flip window. Reviewed-by:
Alex Deucher <alexander.deucher@amd.com> Signed-off-by:
Michel Dänzer <michel.daenzer@amd.com>
-
- Jan 11, 2017
-
-
A client which is attended while a grab is blocking execution of its requests needs to be placed in the saved_ready_clients list so that it will get scheduled once the grab terminates. Otherwise, if the client never sends another request, there is no way for it to be placed in the ready_clients list. v2: Wrap comment above mark_client_saved_ready. Remove test for OS_COMM_IGNORED which will always be true. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=99333 Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Keith Packard <keithp@keithp.com>
-
- Jan 02, 2017
-
-
The custom os/os.O library reuses *.o files of os/libos.la. The current rule assumes automake puts all the objects into per-target am__*_la_OBJECTS variable. At least with AC_REPLACE_FUNCS, this no longer holds (as wanted objects are put into LTLIBOBJS instead). Depend on automake's result, the *.la library instead, to express demand of any its dependencies being built. Should be fixing randomly occuring "undefined reference to `strlcpy'" errors when linking Xvfb and other DDX-es that could use os.O. Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Mihail Konev <k.mvc@ya.ru>
-
- Dec 12, 2016
-
-
Adam Jackson authored
... instead of in all the CreateScratchGC callers. Signed-off-by:
Adam Jackson <ajax@redhat.com> Reviewed-by:
Keith Packard <keithp@keithp.com>
-
Adam Jackson authored
Signed-off-by:
Adam Jackson <ajax@redhat.com> Reviewed-by:
Keith Packard <keithp@keithp.com>
-
- Nov 29, 2016
-
-
Commits 81601564 and fee0827a made it so that wl_keyboard::enter doesn't result in X clients getting KeyPress events while still updating our internal xkb state to be in sync with the host compositor. wl_keyboard::leave needs to be handled in the same way as its semantics from an X client POV should be the same as an X grab getting triggered, i.e. X clients shouldn't get KeyRelease events for keys that are still down at that point. This patch uses LeaveNotify for these events on wl_keyboard::leave and changes the current use of KeymapNotify to EnterNotify instead just to keep some symmetry between both cases. On ProcessDeviceEvent() we still need to deactivate X grabs if needed for KeyReleases. Signed-off-by:
Rui Matos <tiagomatos@gmail.com> Reviewed-by:
Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by:
Peter Hutterer <peter.hutterer@who-t.net>
-
- Nov 15, 2016
-
-
Keith Packard authored
I think it is possible that output could get queued to a client during CloseDownClient. After it is removed from the pending queue, active grabs are released, the client is awoken if sleeping and any work queue entries related to the client are processed. To fix this, move the call removing it from the output_pending chain until after clientGone has been set and then check clientGone in output_pending_mark. Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1382444 Signed-off-by:
Keith Packard <keithp@keithp.com> Reviewed-by:
Hans de Goede <hdegoede@redhat.com>
-
- Oct 28, 2016
-
-
Keith Packard authored
[This was originally a workaround for a client-side resource leak: http://lists.freedesktop.org/archives/xorg-devel/2012-November/034555.html Obviously that's a broken app, but the performance problem it illustrates - that walking the linked list ends up burning all your CPU time - is real enough. - ajax] v2: Replace with a shorter code sequence which computes the same results for all but numBits == 7 Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Keith Packard <keithp@keithp.com>
-
- Oct 06, 2016
-
-
Always set client->errorValue before returning an error. Test program: int main(int argc, char *argv[]) { int screen = 0; xcb_connection_t *c = xcb_connect(NULL, &screen); if (!c) { printf("Cannot connect\n"); return 1; } xcb_void_cookie_t tok = xcb_free_gc_checked(c, BAD_VALUE); xcb_g_context_error_t *err = (xcb_g_context_error_t *)xcb_request_check(c, tok); if (!err) { printf("Unexpected request success\n"); return 1; } if (err->bad_value != BAD_VALUE) { printf("Error: Got 0x%X, expected 0x%X\n", err->bad_value, BAD_VALUE); return 1; } printf("Success! Got expected bad value of 0x%X\n", BAD_VALUE); return 0; } Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Peter Harris <pharris@opentext.com>
-
- Oct 05, 2016
-
-
Add a valuator mask setter for setting absolute coordinate combined with unaccelerated motion deltas. This will later be used by Xwayland to combine a wl_pointer.motion() event with the unaccelerated delta of a wp_relative_pointer.relative_motion() event. Signed-off-by:
Jonas Ådahl <jadahl@gmail.com> Reviewed-by:
Peter Hutterer <peter.hutterer@who-t.net>
-
- Sep 28, 2016
-
-
GetImage is allowed to return window border contents, so don't remove that from the returned image. Reviewed-by:
Adam Jackson <ajax@redhat.com> Signed-off-by:
Keith Packard <keithp@keithp.com>
-
- Sep 22, 2016
-
-
Jeremy Huddleston Sequoia authored
This allows us to remove darwinEvents_lock() and darwinEvents_unlock() and remove the serverRunning hack from dix Signed-off-by:
Jeremy Huddleston Sequoia <jeremyhu@apple.com>
-