summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Turney <jon.turney@dronecode.org.uk>2017-01-16 17:07:24 +0000
committerJon Turney <jon.turney@dronecode.org.uk>2017-01-16 17:07:24 +0000
commit981aea91c02aa0557fe1148e3c0be249b492b1e0 (patch)
treea3ffa3f27a53eadca77796432cc2a0f81b5c6067
parent57042ee319b3bd65bb81f3b1c51255467c4ed553 (diff)
parentad2facda30f453d749492c51d29f2626aee6326a (diff)
Merge tag 'xorg-server-1.19.1' into cygwin-release-1.19
xserver 1.19.1
-rw-r--r--Xi/exevents.c22
-rw-r--r--Xi/xichangehierarchy.c6
-rw-r--r--composite/compalloc.c6
-rw-r--r--composite/compint.h2
-rw-r--r--composite/compwindow.c9
-rw-r--r--configure.ac6
-rw-r--r--dix/Makefile.am4
-rw-r--r--dix/dispatch.c10
-rw-r--r--dix/getevents.c5
-rw-r--r--glamor/glamor.c11
-rw-r--r--glamor/glamor_egl.c4
-rw-r--r--glamor/glamor_egl.h6
-rw-r--r--hw/xfree86/common/xf86AutoConfig.c9
-rw-r--r--hw/xfree86/common/xf86Option.c2
-rw-r--r--hw/xfree86/modes/xf86EdidModes.c5
-rw-r--r--hw/xfree86/parser/read.c16
-rw-r--r--hw/xfree86/parser/xf86Parser.h1
-rw-r--r--hw/xwayland/xwayland-input.c25
-rw-r--r--include/dixstruct.h6
-rw-r--r--miext/damage/damage.c121
-rw-r--r--os/Makefile.am4
-rw-r--r--os/WaitFor.c4
-rw-r--r--os/connection.c4
-rw-r--r--present/present.c5
-rw-r--r--randr/rrcrtc.c10
-rw-r--r--randr/rrprovider.c3
-rw-r--r--randr/rrxinerama.c7
-rw-r--r--test/Makefile.am4
28 files changed, 204 insertions, 113 deletions
diff --git a/Xi/exevents.c b/Xi/exevents.c
index fc5298e37..17d751e31 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -1798,15 +1798,19 @@ ProcessDeviceEvent(InternalEvent *ev, DeviceIntPtr device)
break;
}
- if (grab)
- DeliverGrabbedEvent((InternalEvent *) event, device,
- deactivateDeviceGrab);
- else if (device->focus && !IsPointerEvent(ev))
- DeliverFocusedEvent(device, (InternalEvent *) event,
- GetSpriteWindow(device));
- else
- DeliverDeviceEvents(GetSpriteWindow(device), (InternalEvent *) event,
- NullGrab, NullWindow, device);
+ /* Don't deliver focus events (e.g. from KeymapNotify when running
+ * nested) to clients. */
+ if (event->source_type != EVENT_SOURCE_FOCUS) {
+ if (grab)
+ DeliverGrabbedEvent((InternalEvent *) event, device,
+ deactivateDeviceGrab);
+ else if (device->focus && !IsPointerEvent(ev))
+ DeliverFocusedEvent(device, (InternalEvent *) event,
+ GetSpriteWindow(device));
+ else
+ DeliverDeviceEvents(GetSpriteWindow(device), (InternalEvent *) event,
+ NullGrab, NullWindow, device);
+ }
if (deactivateDeviceGrab == TRUE) {
(*device->deviceGrab.DeactivateGrab) (device);
diff --git a/Xi/xichangehierarchy.c b/Xi/xichangehierarchy.c
index 8d5b577b6..f2b7785ad 100644
--- a/Xi/xichangehierarchy.c
+++ b/Xi/xichangehierarchy.c
@@ -194,7 +194,8 @@ add_master(ClientPtr client, xXIAddMasterInfo * c, int flags[MAXDEVICES])
flags[XTestptr->id] |= XISlaveAttached;
flags[XTestkeybd->id] |= XISlaveAttached;
- XIBarrierNewMasterDevice(client, ptr->id);
+ for (int i = 0; i < currentMaxClients; i++)
+ XIBarrierNewMasterDevice(clients[i], ptr->id);
unwind:
free(name);
@@ -300,7 +301,8 @@ remove_master(ClientPtr client, xXIRemoveMasterInfo * r, int flags[MAXDEVICES])
}
}
- XIBarrierRemoveMasterDevice(client, ptr->id);
+ for (int i = 0; i < currentMaxClients; i++)
+ XIBarrierRemoveMasterDevice(clients[i], ptr->id);
/* disable the remove the devices, XTest devices must be done first
else the sprites they rely on will be destroyed */
diff --git a/composite/compalloc.c b/composite/compalloc.c
index e6a203f6b..05ffc7e85 100644
--- a/composite/compalloc.c
+++ b/composite/compalloc.c
@@ -612,7 +612,7 @@ compAllocPixmap(WindowPtr pWin)
else
pWin->redirectDraw = RedirectDrawManual;
- compSetPixmap(pWin, pPixmap);
+ compSetPixmap(pWin, pPixmap, bw);
cw->oldx = COMP_ORIGIN_INVALID;
cw->oldy = COMP_ORIGIN_INVALID;
cw->damageRegistered = FALSE;
@@ -651,7 +651,7 @@ compSetParentPixmap(WindowPtr pWin)
RegionCopy(&pWin->borderClip, &cw->borderClip);
pParentPixmap = (*pScreen->GetWindowPixmap) (pWin->parent);
pWin->redirectDraw = RedirectDrawNone;
- compSetPixmap(pWin, pParentPixmap);
+ compSetPixmap(pWin, pParentPixmap, pWin->borderWidth);
}
/*
@@ -682,7 +682,7 @@ compReallocPixmap(WindowPtr pWin, int draw_x, int draw_y,
if (!pNew)
return FALSE;
cw->pOldPixmap = pOld;
- compSetPixmap(pWin, pNew);
+ compSetPixmap(pWin, pNew, bw);
}
else {
pNew = pOld;
diff --git a/composite/compint.h b/composite/compint.h
index 09241f2a2..f05c2d8a5 100644
--- a/composite/compint.h
+++ b/composite/compint.h
@@ -274,7 +274,7 @@ void
#endif
void
- compSetPixmap(WindowPtr pWin, PixmapPtr pPixmap);
+ compSetPixmap(WindowPtr pWin, PixmapPtr pPixmap, int bw);
Bool
compCheckRedirect(WindowPtr pWin);
diff --git a/composite/compwindow.c b/composite/compwindow.c
index 344138ad7..bcd230c37 100644
--- a/composite/compwindow.c
+++ b/composite/compwindow.c
@@ -89,6 +89,7 @@ compCheckTree(ScreenPtr pScreen)
typedef struct _compPixmapVisit {
WindowPtr pWindow;
PixmapPtr pPixmap;
+ int bw;
} CompPixmapVisitRec, *CompPixmapVisitPtr;
static Bool
@@ -126,19 +127,20 @@ compSetPixmapVisitWindow(WindowPtr pWindow, void *data)
*/
SetWinSize(pWindow);
SetBorderSize(pWindow);
- if (HasBorder(pWindow))
+ if (pVisit->bw)
QueueWorkProc(compRepaintBorder, serverClient,
(void *) (intptr_t) pWindow->drawable.id);
return WT_WALKCHILDREN;
}
void
-compSetPixmap(WindowPtr pWindow, PixmapPtr pPixmap)
+compSetPixmap(WindowPtr pWindow, PixmapPtr pPixmap, int bw)
{
CompPixmapVisitRec visitRec;
visitRec.pWindow = pWindow;
visitRec.pPixmap = pPixmap;
+ visitRec.bw = bw;
TraverseTree(pWindow, compSetPixmapVisitWindow, (void *) &visitRec);
compCheckTree(pWindow->drawable.pScreen);
}
@@ -463,7 +465,8 @@ compReparentWindow(WindowPtr pWin, WindowPtr pPriorParent)
* Reset pixmap pointers as appropriate
*/
if (pWin->parent && pWin->redirectDraw == RedirectDrawNone)
- compSetPixmap(pWin, (*pScreen->GetWindowPixmap) (pWin->parent));
+ compSetPixmap(pWin, (*pScreen->GetWindowPixmap) (pWin->parent),
+ pWin->borderWidth);
/*
* Call down to next function
*/
diff --git a/configure.ac b/configure.ac
index 0e30f406f..b1c40ee28 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,9 +26,9 @@ dnl
dnl Process this file with autoconf to create configure.
AC_PREREQ(2.60)
-AC_INIT([xorg-server], 1.19.0, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
-RELEASE_DATE="2016-11-15"
-RELEASE_NAME="Cioppino"
+AC_INIT([xorg-server], 1.19.1, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
+RELEASE_DATE="2017-01-11"
+RELEASE_NAME="Maeuntang"
AC_CONFIG_SRCDIR([Makefile.am])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([foreign dist-bzip2])
diff --git a/dix/Makefile.am b/dix/Makefile.am
index e7ca2369c..a4171d7e1 100644
--- a/dix/Makefile.am
+++ b/dix/Makefile.am
@@ -61,13 +61,13 @@ endif
if SPECIAL_DTRACE_OBJECTS
# Generate dtrace object code for probes in libdix
-dtrace-dix.o: $(top_srcdir)/dix/Xserver.d $(am_libdix_la_OBJECTS)
+dtrace-dix.o: $(top_srcdir)/dix/Xserver.d libdix.la
$(AM_V_GEN)$(DTRACE) -G -C -o $@ -s $(top_srcdir)/dix/Xserver.d $(am_libdix_la_OBJECTS:%.lo=.libs/%.o)
noinst_PROGRAMS = dix.O
dix_O_SOURCES =
-dix.O: dtrace-dix.o $(am_libdix_la_OBJECTS)
+dix.O: dtrace-dix.o libdix.la
$(AM_V_GEN)ld -r -o $@ $(am_libdix_la_OBJECTS:%.lo=.libs/%.o)
endif
diff --git a/dix/dispatch.c b/dix/dispatch.c
index 3d0fe26fd..78ac095b1 100644
--- a/dix/dispatch.c
+++ b/dix/dispatch.c
@@ -266,6 +266,16 @@ mark_client_ready(ClientPtr client)
xorg_list_append(&client->ready, &ready_clients);
}
+/*
+ * Client has requests queued or data on the network, but awaits a
+ * server grab release
+ */
+void mark_client_saved_ready(ClientPtr client)
+{
+ if (xorg_list_is_empty(&client->ready))
+ xorg_list_append(&client->ready, &saved_ready_clients);
+}
+
/* Client has no requests queued and no data on network */
void
mark_client_not_ready(ClientPtr client)
diff --git a/dix/getevents.c b/dix/getevents.c
index 4d06818cf..0d87453e5 100644
--- a/dix/getevents.c
+++ b/dix/getevents.c
@@ -1101,9 +1101,12 @@ GetKeyboardEvents(InternalEvent *events, DeviceIntPtr pDev, int type,
}
#endif
- if (type == KeymapNotify) {
+ if (type == EnterNotify) {
source_type = EVENT_SOURCE_FOCUS;
type = KeyPress;
+ } else if (type == LeaveNotify) {
+ source_type = EVENT_SOURCE_FOCUS;
+ type = KeyRelease;
}
/* refuse events from disabled devices */
diff --git a/glamor/glamor.c b/glamor/glamor.c
index b7718325d..c54cf3b43 100644
--- a/glamor/glamor.c
+++ b/glamor/glamor.c
@@ -470,7 +470,7 @@ glamor_init(ScreenPtr screen, unsigned int flags)
LogMessage(X_WARNING,
"glamor%d: Failed to allocate screen private\n",
screen->myNum);
- goto fail;
+ goto free_glamor_private;
}
glamor_set_screen_private(screen, glamor_priv);
@@ -480,7 +480,7 @@ glamor_init(ScreenPtr screen, unsigned int flags)
LogMessage(X_WARNING,
"glamor%d: Failed to allocate pixmap private\n",
screen->myNum);
- goto fail;
+ goto free_glamor_private;
}
if (!dixRegisterPrivateKey(&glamor_gc_private_key, PRIVATE_GC,
@@ -488,7 +488,7 @@ glamor_init(ScreenPtr screen, unsigned int flags)
LogMessage(X_WARNING,
"glamor%d: Failed to allocate gc private\n",
screen->myNum);
- goto fail;
+ goto free_glamor_private;
}
glamor_priv->saved_procs.close_screen = screen->CloseScreen;
@@ -731,6 +731,11 @@ glamor_init(ScreenPtr screen, unsigned int flags)
return TRUE;
fail:
+ /* Restore default CloseScreen and DestroyPixmap handlers */
+ screen->CloseScreen = glamor_priv->saved_procs.close_screen;
+ screen->DestroyPixmap = glamor_priv->saved_procs.destroy_pixmap;
+
+ free_glamor_private:
free(glamor_priv);
glamor_set_screen_private(screen, NULL);
return FALSE;
diff --git a/glamor/glamor_egl.c b/glamor/glamor_egl.c
index 9cc0f8d6e..4bde637a0 100644
--- a/glamor/glamor_egl.c
+++ b/glamor/glamor_egl.c
@@ -769,6 +769,10 @@ glamor_egl_init(ScrnInfoPtr scrn, int fd)
glamor_egl->display = glamor_egl_get_display(EGL_PLATFORM_GBM_MESA,
glamor_egl->gbm);
+ if (!glamor_egl->display) {
+ xf86DrvMsg(scrn->scrnIndex, X_ERROR, "eglGetDisplay() failed\n");
+ goto error;
+ }
#else
glamor_egl->display = eglGetDisplay((EGLNativeDisplayType) (intptr_t) fd);
#endif
diff --git a/glamor/glamor_egl.h b/glamor/glamor_egl.h
index 6b05f576f..6bb1185bf 100644
--- a/glamor/glamor_egl.h
+++ b/glamor/glamor_egl.h
@@ -60,16 +60,12 @@
static inline EGLDisplay
glamor_egl_get_display(EGLint type, void *native)
{
- EGLDisplay dpy = NULL;
-
/* In practise any EGL 1.5 implementation would support the EXT extension */
if (epoxy_has_egl_extension(NULL, "EGL_EXT_platform_base")) {
PFNEGLGETPLATFORMDISPLAYEXTPROC getPlatformDisplayEXT =
(void *) eglGetProcAddress("eglGetPlatformDisplayEXT");
if (getPlatformDisplayEXT)
- dpy = getPlatformDisplayEXT(type, native, NULL);
- if (dpy)
- return dpy;
+ return getPlatformDisplayEXT(type, native, NULL);
}
/* Welp, everything is awful. */
diff --git a/hw/xfree86/common/xf86AutoConfig.c b/hw/xfree86/common/xf86AutoConfig.c
index 940265144..c3e17beb7 100644
--- a/hw/xfree86/common/xf86AutoConfig.c
+++ b/hw/xfree86/common/xf86AutoConfig.c
@@ -149,6 +149,15 @@ xf86AutoConfig(void)
char buf[1024];
ConfigStatus ret;
+ /* Make sure config rec is there */
+ if (xf86allocateConfig() != NULL) {
+ ret = CONFIG_OK; /* OK so far */
+ }
+ else {
+ xf86Msg(X_ERROR, "Couldn't allocate Config record.\n");
+ return FALSE;
+ }
+
listPossibleVideoDrivers(deviceList, 20);
for (p = deviceList; *p; p++) {
diff --git a/hw/xfree86/common/xf86Option.c b/hw/xfree86/common/xf86Option.c
index 0e8bc1f83..e9393fa16 100644
--- a/hw/xfree86/common/xf86Option.c
+++ b/hw/xfree86/common/xf86Option.c
@@ -84,7 +84,7 @@ xf86CollectOptions(ScrnInfoPtr pScrn, XF86OptionPtr extraOpts)
if (device && device->options) {
tmp = xf86optionListDup(device->options);
if (pScrn->options)
- xf86optionListMerge(pScrn->options, tmp);
+ pScrn->options = xf86optionListMerge(pScrn->options, tmp);
else
pScrn->options = tmp;
}
diff --git a/hw/xfree86/modes/xf86EdidModes.c b/hw/xfree86/modes/xf86EdidModes.c
index f24294ee3..f0e1e974b 100644
--- a/hw/xfree86/modes/xf86EdidModes.c
+++ b/hw/xfree86/modes/xf86EdidModes.c
@@ -153,6 +153,11 @@ quirk_detailed_v_in_cm(int scrnIndex, xf86MonPtr DDC)
static Bool
quirk_detailed_use_maximum_size(int scrnIndex, xf86MonPtr DDC)
{
+ /* ADA 1024x600 7" display */
+ if (memcmp(DDC->vendor.name, "ADA", 4) == 0 &&
+ DDC->vendor.prod_id == 4)
+ return TRUE;
+
/* Bug #21324: Iiyama Vision Master 450 */
if (memcmp(DDC->vendor.name, "IVM", 4) == 0 && DDC->vendor.prod_id == 6400)
return TRUE;
diff --git a/hw/xfree86/parser/read.c b/hw/xfree86/parser/read.c
index ec038aeb1..d7e731217 100644
--- a/hw/xfree86/parser/read.c
+++ b/hw/xfree86/parser/read.c
@@ -56,6 +56,7 @@
#include <xorg-config.h>
#endif
+#include "xf86Config.h"
#include "xf86Parser.h"
#include "xf86tokens.h"
#include "Configint.h"
@@ -91,7 +92,7 @@ xf86readConfigFile(void)
int token;
XF86ConfigPtr ptr = NULL;
- if ((ptr = calloc(1, sizeof(XF86ConfigRec))) == NULL) {
+ if ((ptr = xf86allocateConfig()) == NULL) {
return NULL;
}
@@ -270,6 +271,19 @@ xf86itemNotSublist(GenericListPtr list_1, GenericListPtr list_2)
return (!(last_1 == last_2));
}
+/*
+ * Conditionally allocate config struct, but only allocate it
+ * if it's not already there. In either event, return the pointer
+ * to the global config struct.
+ */
+XF86ConfigPtr xf86allocateConfig(void)
+{
+ if (!xf86configptr) {
+ xf86configptr = calloc(1, sizeof(XF86ConfigRec));
+ }
+ return xf86configptr;
+}
+
void
xf86freeConfig(XF86ConfigPtr p)
{
diff --git a/hw/xfree86/parser/xf86Parser.h b/hw/xfree86/parser/xf86Parser.h
index ff35846e9..9c4b40370 100644
--- a/hw/xfree86/parser/xf86Parser.h
+++ b/hw/xfree86/parser/xf86Parser.h
@@ -449,6 +449,7 @@ extern char *xf86openConfigDirFiles(const char *path, const char *cmdline,
extern void xf86setBuiltinConfig(const char *config[]);
extern XF86ConfigPtr xf86readConfigFile(void);
extern void xf86closeConfigFile(void);
+extern XF86ConfigPtr xf86allocateConfig(void);
extern void xf86freeConfig(XF86ConfigPtr p);
extern int xf86writeConfigFile(const char *, XF86ConfigPtr);
extern _X_EXPORT XF86ConfDevicePtr xf86findDevice(const char *ident,
diff --git a/hw/xwayland/xwayland-input.c b/hw/xwayland/xwayland-input.c
index 7ec3b1a68..ecf0b7a62 100644
--- a/hw/xwayland/xwayland-input.c
+++ b/hw/xwayland/xwayland-input.c
@@ -318,6 +318,9 @@ pointer_handle_enter(void *data, struct wl_pointer *pointer,
dx = xwl_seat->focus_window->window->drawable.x;
dy = xwl_seat->focus_window->window->drawable.y;
+ /* We just entered a new xwindow, forget about the old last xwindow */
+ xwl_seat->last_xwindow = NullWindow;
+
master = GetMaster(dev, POINTER_OR_FLOAT);
(*pScreen->SetCursorPosition) (dev, pScreen, dx + sx, dy + sy, TRUE);
@@ -366,8 +369,14 @@ pointer_handle_leave(void *data, struct wl_pointer *pointer,
xwl_seat->xwl_screen->serial = serial;
- xwl_seat->focus_window = NULL;
- CheckMotion(NULL, GetMaster(dev, POINTER_OR_FLOAT));
+ /* The pointer has left a known xwindow, save it for a possible match
+ * in sprite_check_lost_focus()
+ */
+ if (xwl_seat->focus_window) {
+ xwl_seat->last_xwindow = xwl_seat->focus_window->window;
+ xwl_seat->focus_window = NULL;
+ CheckMotion(NULL, GetMaster(dev, POINTER_OR_FLOAT));
+ }
}
static void
@@ -646,7 +655,7 @@ keyboard_handle_enter(void *data, struct wl_keyboard *keyboard,
wl_array_copy(&xwl_seat->keys, keys);
wl_array_for_each(k, &xwl_seat->keys)
- QueueKeyboardEvents(xwl_seat->keyboard, KeymapNotify, *k + 8);
+ QueueKeyboardEvents(xwl_seat->keyboard, EnterNotify, *k + 8);
}
static void
@@ -658,12 +667,8 @@ keyboard_handle_leave(void *data, struct wl_keyboard *keyboard,
xwl_seat->xwl_screen->serial = serial;
- /* Unlike keymap_handle_enter above, this time we _do_ want to trigger
- * full release, as we don't know how long we'll be out of focus for.
- * Notify clients that the keys have been released, disable autorepeat,
- * etc. */
wl_array_for_each(k, &xwl_seat->keys)
- QueueKeyboardEvents(xwl_seat->keyboard, KeyRelease, *k + 8);
+ QueueKeyboardEvents(xwl_seat->keyboard, LeaveNotify, *k + 8);
xwl_seat->keyboard_focus = NULL;
}
@@ -1262,10 +1267,10 @@ sprite_check_lost_focus(SpritePtr sprite, WindowPtr window)
*/
if (master->lastSlave == xwl_seat->pointer &&
xwl_seat->focus_window == NULL &&
- xwl_seat->last_xwindow == window)
+ xwl_seat->last_xwindow != NullWindow &&
+ IsParent(xwl_seat->last_xwindow, window))
return TRUE;
- xwl_seat->last_xwindow = window;
return FALSE;
}
diff --git a/include/dixstruct.h b/include/dixstruct.h
index d71b0ac05..21a6b8a8d 100644
--- a/include/dixstruct.h
+++ b/include/dixstruct.h
@@ -143,6 +143,12 @@ extern void SmartScheduleStopTimer(void);
/* Client has requests queued or data on the network */
void mark_client_ready(ClientPtr client);
+/*
+ * Client has requests queued or data on the network, but awaits a
+ * server grab release
+ */
+void mark_client_saved_ready(ClientPtr client);
+
/* Client has no requests queued and no data on network */
void mark_client_not_ready(ClientPtr client);
diff --git a/miext/damage/damage.c b/miext/damage/damage.c
index 17c2abfff..d6a36142d 100644
--- a/miext/damage/damage.c
+++ b/miext/damage/damage.c
@@ -282,8 +282,10 @@ damageRegionAppend(DrawablePtr pDrawable, RegionPtr pRegion, Bool clip,
}
static void
-damageRegionProcessPending(DamagePtr pDamage)
+damageRegionProcessPending(DrawablePtr pDrawable)
{
+ drawableDamage(pDrawable);
+
for (; pDamage != NULL; pDamage = pDamage->pNext) {
if (pDamage->reportAfter) {
/* It's possible that there is only interest in postRendering reporting. */
@@ -358,7 +360,6 @@ damageCreateGC(GCPtr pGC)
#define DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable) \
damageGCPriv(pGC); \
- drawableDamage(pDrawable); \
const GCFuncs *oldFuncs = pGC->funcs; \
unwrap(pGCPriv, pGC, funcs); \
unwrap(pGCPriv, pGC, ops); \
@@ -456,7 +457,7 @@ damageDestroyClip(GCPtr pGC)
#define BOX_NOT_EMPTY(box) \
(((box.x2 - box.x1) > 0) && ((box.y2 - box.y1) > 0))
-#define checkGCDamage(d,g) (d && \
+#define checkGCDamage(d,g) (getDrawableDamage(d) && \
(!g->pCompositeClip ||\
RegionNotEmpty(g->pCompositeClip)))
@@ -468,7 +469,8 @@ damageDestroyClip(GCPtr pGC)
if(box.y2 > extents->y2) box.y2 = extents->y2; \
}
-#define checkPictureDamage(d, p) (d && RegionNotEmpty(p->pCompositeClip))
+#define checkPictureDamage(p) (getDrawableDamage(p->pDrawable) && \
+ RegionNotEmpty(p->pCompositeClip))
static void
damageComposite(CARD8 op,
@@ -485,9 +487,8 @@ damageComposite(CARD8 op,
PictureScreenPtr ps = GetPictureScreen(pScreen);
damageScrPriv(pScreen);
- drawableDamage(pDst->pDrawable);
- if (checkPictureDamage(pDamage, pDst)) {
+ if (checkPictureDamage(pDst)) {
BoxRec box;
box.x1 = xDst + pDst->pDrawable->x;
@@ -504,7 +505,7 @@ damageComposite(CARD8 op,
pMask,
pDst,
xSrc, ySrc, xMask, yMask, xDst, yDst, width, height);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDst->pDrawable);
wrap(pScrPriv, ps, Composite, damageComposite);
}
@@ -520,9 +521,8 @@ damageGlyphs(CARD8 op,
PictureScreenPtr ps = GetPictureScreen(pScreen);
damageScrPriv(pScreen);
- drawableDamage(pDst->pDrawable);
- if (checkPictureDamage(pDamage, pDst)) {
+ if (checkPictureDamage(pDst)) {
int nlistTmp = nlist;
GlyphListPtr listTmp = list;
GlyphPtr *glyphsTmp = glyphs;
@@ -567,7 +567,7 @@ damageGlyphs(CARD8 op,
}
unwrap(pScrPriv, ps, Glyphs);
(*ps->Glyphs) (op, pSrc, pDst, maskFormat, xSrc, ySrc, nlist, list, glyphs);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDst->pDrawable);
wrap(pScrPriv, ps, Glyphs, damageGlyphs);
}
@@ -579,9 +579,8 @@ damageAddTraps(PicturePtr pPicture,
PictureScreenPtr ps = GetPictureScreen(pScreen);
damageScrPriv(pScreen);
- drawableDamage(pPicture->pDrawable);
- if (checkPictureDamage(pDamage, pPicture)) {
+ if (checkPictureDamage(pPicture)) {
BoxRec box;
int i;
int x, y;
@@ -616,7 +615,7 @@ damageAddTraps(PicturePtr pPicture,
}
unwrap(pScrPriv, ps, AddTraps);
(*ps->AddTraps) (pPicture, x_off, y_off, ntrap, traps);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pPicture->pDrawable);
wrap(pScrPriv, ps, AddTraps, damageAddTraps);
}
@@ -628,7 +627,7 @@ damageFillSpans(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (npt && checkGCDamage(pDamage, pGC)) {
+ if (npt && checkGCDamage(pDrawable, pGC)) {
int nptTmp = npt;
DDXPointPtr pptTmp = ppt;
int *pwidthTmp = pwidth;
@@ -664,7 +663,7 @@ damageFillSpans(DrawablePtr pDrawable,
(*pGC->ops->FillSpans) (pDrawable, pGC, npt, ppt, pwidth, fSorted);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -676,7 +675,7 @@ damageSetSpans(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (npt && checkGCDamage(pDamage, pGC)) {
+ if (npt && checkGCDamage(pDrawable, pGC)) {
DDXPointPtr pptTmp = ppt;
int *pwidthTmp = pwidth;
int nptTmp = npt;
@@ -710,7 +709,7 @@ damageSetSpans(DrawablePtr pDrawable,
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->SetSpans) (pDrawable, pGC, pcharsrc, ppt, pwidth, npt, fSorted);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -722,7 +721,7 @@ damagePutImage(DrawablePtr pDrawable,
int y, int w, int h, int leftPad, int format, char *pImage)
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (checkGCDamage(pDamage, pGC)) {
+ if (checkGCDamage(pDrawable, pGC)) {
BoxRec box;
box.x1 = x + pDrawable->x;
@@ -736,7 +735,7 @@ damagePutImage(DrawablePtr pDrawable,
}
(*pGC->ops->PutImage) (pDrawable, pGC, depth, x, y, w, h,
leftPad, format, pImage);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -750,7 +749,7 @@ damageCopyArea(DrawablePtr pSrc,
DAMAGE_GC_OP_PROLOGUE(pGC, pDst);
- if (checkGCDamage(pDamage, pGC)) {
+ if (checkGCDamage(pDst, pGC)) {
BoxRec box;
box.x1 = dstx + pDst->x;
@@ -765,7 +764,7 @@ damageCopyArea(DrawablePtr pSrc,
ret = (*pGC->ops->CopyArea) (pSrc, pDst,
pGC, srcx, srcy, width, height, dstx, dsty);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDst);
DAMAGE_GC_OP_EPILOGUE(pGC, pDst);
return ret;
}
@@ -783,7 +782,7 @@ damageCopyPlane(DrawablePtr pSrc,
DAMAGE_GC_OP_PROLOGUE(pGC, pDst);
- if (checkGCDamage(pDamage, pGC)) {
+ if (checkGCDamage(pDst, pGC)) {
BoxRec box;
box.x1 = dstx + pDst->x;
@@ -799,7 +798,7 @@ damageCopyPlane(DrawablePtr pSrc,
ret = (*pGC->ops->CopyPlane) (pSrc, pDst,
pGC, srcx, srcy, width, height, dstx, dsty,
bitPlane);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDst);
DAMAGE_GC_OP_EPILOGUE(pGC, pDst);
return ret;
}
@@ -810,7 +809,7 @@ damagePolyPoint(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (npt && checkGCDamage(pDamage, pGC)) {
+ if (npt && checkGCDamage(pDrawable, pGC)) {
BoxRec box;
int nptTmp = npt;
xPoint *pptTmp = ppt;
@@ -840,7 +839,7 @@ damagePolyPoint(DrawablePtr pDrawable,
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->PolyPoint) (pDrawable, pGC, mode, npt, ppt);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -850,7 +849,7 @@ damagePolylines(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (npt && checkGCDamage(pDamage, pGC)) {
+ if (npt && checkGCDamage(pDrawable, pGC)) {
int nptTmp = npt;
DDXPointPtr pptTmp = ppt;
BoxRec box;
@@ -913,7 +912,7 @@ damagePolylines(DrawablePtr pDrawable,
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->Polylines) (pDrawable, pGC, mode, npt, ppt);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -922,7 +921,7 @@ damagePolySegment(DrawablePtr pDrawable, GCPtr pGC, int nSeg, xSegment * pSeg)
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (nSeg && checkGCDamage(pDamage, pGC)) {
+ if (nSeg && checkGCDamage(pDrawable, pGC)) {
BoxRec box;
int extra = pGC->lineWidth;
int nsegTmp = nSeg;
@@ -992,7 +991,7 @@ damagePolySegment(DrawablePtr pDrawable, GCPtr pGC, int nSeg, xSegment * pSeg)
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->PolySegment) (pDrawable, pGC, nSeg, pSeg);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1002,7 +1001,7 @@ damagePolyRectangle(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (nRects && checkGCDamage(pDamage, pGC)) {
+ if (nRects && checkGCDamage(pDrawable, pGC)) {
BoxRec box;
int offset1, offset2, offset3;
int nRectsTmp = nRects;
@@ -1051,7 +1050,7 @@ damagePolyRectangle(DrawablePtr pDrawable,
}
}
(*pGC->ops->PolyRectangle) (pDrawable, pGC, nRects, pRects);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1060,7 +1059,7 @@ damagePolyArc(DrawablePtr pDrawable, GCPtr pGC, int nArcs, xArc * pArcs)
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (nArcs && checkGCDamage(pDamage, pGC)) {
+ if (nArcs && checkGCDamage(pDrawable, pGC)) {
int extra = pGC->lineWidth >> 1;
BoxRec box;
int nArcsTmp = nArcs;
@@ -1098,7 +1097,7 @@ damagePolyArc(DrawablePtr pDrawable, GCPtr pGC, int nArcs, xArc * pArcs)
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->PolyArc) (pDrawable, pGC, nArcs, pArcs);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1108,7 +1107,7 @@ damageFillPolygon(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (npt > 2 && checkGCDamage(pDamage, pGC)) {
+ if (npt > 2 && checkGCDamage(pDrawable, pGC)) {
DDXPointPtr pptTmp = ppt;
int nptTmp = npt;
BoxRec box;
@@ -1157,7 +1156,7 @@ damageFillPolygon(DrawablePtr pDrawable,
}
(*pGC->ops->FillPolygon) (pDrawable, pGC, shape, mode, npt, ppt);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1166,7 +1165,7 @@ damagePolyFillRect(DrawablePtr pDrawable,
GCPtr pGC, int nRects, xRectangle *pRects)
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (nRects && checkGCDamage(pDamage, pGC)) {
+ if (nRects && checkGCDamage(pDrawable, pGC)) {
BoxRec box;
xRectangle *pRectsTmp = pRects;
int nRectsTmp = nRects;
@@ -1193,7 +1192,7 @@ damagePolyFillRect(DrawablePtr pDrawable,
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->PolyFillRect) (pDrawable, pGC, nRects, pRects);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1202,7 +1201,7 @@ damagePolyFillArc(DrawablePtr pDrawable, GCPtr pGC, int nArcs, xArc * pArcs)
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (nArcs && checkGCDamage(pDamage, pGC)) {
+ if (nArcs && checkGCDamage(pDrawable, pGC)) {
BoxRec box;
int nArcsTmp = nArcs;
xArc *pArcsTmp = pArcs;
@@ -1229,7 +1228,7 @@ damagePolyFillArc(DrawablePtr pDrawable, GCPtr pGC, int nArcs, xArc * pArcs)
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->PolyFillArc) (pDrawable, pGC, nArcs, pArcs);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1278,9 +1277,12 @@ damageDamageChars(DrawablePtr pDrawable,
#define TT_IMAGE16 3
static void
-damageText(DrawablePtr pDrawable, GCPtr pGC, int x, int y, unsigned long count,
- char *chars, FontEncoding fontEncoding, DamagePtr pDamage,
- Bool textType)
+damageText(DrawablePtr pDrawable,
+ GCPtr pGC,
+ int x,
+ int y,
+ unsigned long count,
+ char *chars, FontEncoding fontEncoding, Bool textType)
{
CharInfoPtr *charinfo;
unsigned long i;
@@ -1289,7 +1291,7 @@ damageText(DrawablePtr pDrawable, GCPtr pGC, int x, int y, unsigned long count,
imageblt = (textType == TT_IMAGE8) || (textType == TT_IMAGE16);
- if (!pDamage)
+ if (!checkGCDamage(pDrawable, pGC))
return;
charinfo = xallocarray(count, sizeof(CharInfoPtr));
@@ -1314,9 +1316,9 @@ damagePolyText8(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
damageText(pDrawable, pGC, x, y, (unsigned long) count, chars, Linear8Bit,
- pDamage, TT_POLY8);
+ TT_POLY8);
x = (*pGC->ops->PolyText8) (pDrawable, pGC, x, y, count, chars);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
return x;
}
@@ -1328,9 +1330,9 @@ damagePolyText16(DrawablePtr pDrawable,
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
damageText(pDrawable, pGC, x, y, (unsigned long) count, (char *) chars,
FONTLASTROW(pGC->font) == 0 ? Linear16Bit : TwoD16Bit,
- pDamage, TT_POLY16);
+ TT_POLY16);
x = (*pGC->ops->PolyText16) (pDrawable, pGC, x, y, count, chars);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
return x;
}
@@ -1341,9 +1343,9 @@ damageImageText8(DrawablePtr pDrawable,
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
damageText(pDrawable, pGC, x, y, (unsigned long) count, chars, Linear8Bit,
- pDamage, TT_IMAGE8);
+ TT_IMAGE8);
(*pGC->ops->ImageText8) (pDrawable, pGC, x, y, count, chars);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1354,9 +1356,9 @@ damageImageText16(DrawablePtr pDrawable,
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
damageText(pDrawable, pGC, x, y, (unsigned long) count, (char *) chars,
FONTLASTROW(pGC->font) == 0 ? Linear16Bit : TwoD16Bit,
- pDamage, TT_IMAGE16);
+ TT_IMAGE16);
(*pGC->ops->ImageText16) (pDrawable, pGC, x, y, count, chars);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1371,7 +1373,7 @@ damageImageGlyphBlt(DrawablePtr pDrawable,
damageDamageChars(pDrawable, pGC->font, x + pDrawable->x, y + pDrawable->y,
nglyph, ppci, TRUE, pGC->subWindowMode);
(*pGC->ops->ImageGlyphBlt) (pDrawable, pGC, x, y, nglyph, ppci, pglyphBase);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1386,7 +1388,7 @@ damagePolyGlyphBlt(DrawablePtr pDrawable,
damageDamageChars(pDrawable, pGC->font, x + pDrawable->x, y + pDrawable->y,
nglyph, ppci, FALSE, pGC->subWindowMode);
(*pGC->ops->PolyGlyphBlt) (pDrawable, pGC, x, y, nglyph, ppci, pglyphBase);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1396,7 +1398,7 @@ damagePushPixels(GCPtr pGC,
DrawablePtr pDrawable, int dx, int dy, int xOrg, int yOrg)
{
DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
- if (checkGCDamage(pDamage, pGC)) {
+ if (checkGCDamage(pDrawable, pGC)) {
BoxRec box;
box.x1 = xOrg;
@@ -1415,7 +1417,7 @@ damagePushPixels(GCPtr pGC,
damageDamageBox(pDrawable, &box, pGC->subWindowMode);
}
(*pGC->ops->PushPixels) (pGC, pBitMap, pDrawable, dx, dy, xOrg, yOrg);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
}
@@ -1480,7 +1482,6 @@ damageCopyWindow(WindowPtr pWindow, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
ScreenPtr pScreen = pWindow->drawable.pScreen;
damageScrPriv(pScreen);
- drawableDamage(&pWindow->drawable);
if (getWindowDamage(pWindow)) {
int dx = pWindow->drawable.x - ptOldOrg.x;
@@ -1496,7 +1497,7 @@ damageCopyWindow(WindowPtr pWindow, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
}
unwrap(pScrPriv, pScreen, CopyWindow);
(*pScreen->CopyWindow) (pWindow, ptOldOrg, prgnSrc);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(&pWindow->drawable);
wrap(pScrPriv, pScreen, CopyWindow, damageCopyWindow);
}
@@ -1870,22 +1871,20 @@ DamageRegionAppend(DrawablePtr pDrawable, RegionPtr pRegion)
void
DamageRegionProcessPending(DrawablePtr pDrawable)
{
- drawableDamage(pDrawable);
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
}
/* This call is very odd, i'm leaving it intact for API sake, but please don't use it. */
void
DamageDamageRegion(DrawablePtr pDrawable, RegionPtr pRegion)
{
- drawableDamage(pDrawable);
damageRegionAppend(pDrawable, pRegion, FALSE, -1);
/* Go back and report this damage for DamagePtrs with reportAfter set, since
* this call isn't part of an in-progress drawing op in the call chain and
* the DDX probably just wants to know about it right away.
*/
- damageRegionProcessPending(pDamage);
+ damageRegionProcessPending(pDrawable);
}
void
diff --git a/os/Makefile.am b/os/Makefile.am
index 51cc29266..673d4b04f 100644
--- a/os/Makefile.am
+++ b/os/Makefile.am
@@ -58,12 +58,12 @@ EXTRA_DIST = $(SECURERPC_SRCS) $(XDMCP_SRCS)
if SPECIAL_DTRACE_OBJECTS
# Generate dtrace object code for probes in libos & libdix
-dtrace.o: $(top_srcdir)/dix/Xserver.d $(am_libos_la_OBJECTS)
+dtrace.o: $(top_srcdir)/dix/Xserver.d libos.la
$(AM_V_GEN)$(DTRACE) -G -C -o $@ -s $(top_srcdir)/dix/Xserver.d .libs/*.o ../dix/.libs/*.o
noinst_PROGRAMS = os.O
os_O_SOURCES =
-os.O: dtrace.o $(am_libos_la_OBJECTS)
+os.O: dtrace.o libos.la
$(AM_V_GEN)ld -r -o $@ dtrace.o .libs/*.o
endif
diff --git a/os/WaitFor.c b/os/WaitFor.c
index ff1c85e3a..613608faf 100644
--- a/os/WaitFor.c
+++ b/os/WaitFor.c
@@ -143,7 +143,7 @@ check_timers(void)
{
OsTimerPtr timer;
- while ((timer = first_timer()) != NULL) {
+ if ((timer = first_timer()) != NULL) {
CARD32 now = GetTimeInMillis();
int timeout = timer->expires - now;
@@ -157,6 +157,8 @@ check_timers(void)
/* time has rewound. reset the timers. */
CheckAllTimers();
}
+
+ return 0;
}
return -1;
}
diff --git a/os/connection.c b/os/connection.c
index 7d6f27e5d..8141fb3f4 100644
--- a/os/connection.c
+++ b/os/connection.c
@@ -1069,6 +1069,10 @@ AttendClient(ClientPtr client)
set_poll_client(client);
if (listen_to_client(client))
mark_client_ready(client);
+ else {
+ /* grab active, mark ready when grab goes away */
+ mark_client_saved_ready(client);
+ }
}
/* make client impervious to grabs; assume only executing client calls this */
diff --git a/present/present.c b/present/present.c
index a7ca06e36..ef8904537 100644
--- a/present/present.c
+++ b/present/present.c
@@ -536,7 +536,10 @@ present_event_notify(uint64_t event_id, uint64_t ust, uint64_t msc)
}
xorg_list_for_each_entry(vblank, &present_flip_queue, event_queue) {
if (vblank->event_id == event_id) {
- present_flip_notify(vblank, ust, msc);
+ if (vblank->queued)
+ present_execute(vblank, ust, msc);
+ else
+ present_flip_notify(vblank, ust, msc);
return;
}
}
diff --git a/randr/rrcrtc.c b/randr/rrcrtc.c
index 5d404e84b..d1a51f0aa 100644
--- a/randr/rrcrtc.c
+++ b/randr/rrcrtc.c
@@ -686,8 +686,14 @@ rrCheckPixmapBounding(ScreenPtr pScreen,
}
newsize = RegionExtents(&total_region);
- new_width = newsize->x2 - newsize->x1;
- new_height = newsize->y2 - newsize->y1;
+ new_width = newsize->x2;
+ new_height = newsize->y2;
+
+ if (new_width < screen_pixmap->drawable.width)
+ new_width = screen_pixmap->drawable.width;
+
+ if (new_height < screen_pixmap->drawable.height)
+ new_height = screen_pixmap->drawable.height;
if (new_width == screen_pixmap->drawable.width &&
new_height == screen_pixmap->drawable.height) {
diff --git a/randr/rrprovider.c b/randr/rrprovider.c
index f9df67e0b..e4bc2bf6a 100644
--- a/randr/rrprovider.c
+++ b/randr/rrprovider.c
@@ -338,6 +338,9 @@ ProcRRSetProviderOutputSource(ClientPtr client)
pScreen = provider->pScreen;
pScrPriv = rrGetScrPriv(pScreen);
+ if (!pScreen->isGPU)
+ return BadValue;
+
pScrPriv->rrProviderSetOutputSource(pScreen, provider, source_provider);
RRInitPrimeSyncProps(pScreen);
diff --git a/randr/rrxinerama.c b/randr/rrxinerama.c
index b6e9586d7..8f499dfa9 100644
--- a/randr/rrxinerama.c
+++ b/randr/rrxinerama.c
@@ -260,6 +260,13 @@ RRXineramaWriteMonitor(ClientPtr client, RRMonitorPtr monitor)
scratch.width = monitor->geometry.box.x2 - monitor->geometry.box.x1;
scratch.height = monitor->geometry.box.y2 - monitor->geometry.box.y1;
+ if (client->swapped) {
+ swaps(&scratch.x_org);
+ swaps(&scratch.y_org);
+ swaps(&scratch.width);
+ swaps(&scratch.height);
+ }
+
WriteToClient(client, sz_XineramaScreenInfo, &scratch);
}
diff --git a/test/Makefile.am b/test/Makefile.am
index db3abbebd..b2358c219 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -66,7 +66,6 @@ xfree86_LDADD=$(TEST_LDADD)
touch_LDADD=$(TEST_LDADD)
signal_logging_LDADD=$(TEST_LDADD)
hashtabletest_LDADD=$(TEST_LDADD)
-os_LDADD=$(TEST_LDADD)
libxservertest_la_LIBADD = $(XSERVER_LIBS)
if XORG
@@ -162,7 +161,8 @@ libxservertest_la_DEPENDENCIES = $(libxservertest_la_LIBADD)
endif
EXTRA_DIST = \
- $(SCRIPT_TESTS) \
+ scripts/xvfb-piglit.sh \
+ scripts/xephyr-glamor-piglit.sh \
scripts/xinit-piglit-session.sh \
scripts/run-piglit.sh \
ddxstubs.c \