debian/changelog | 7 +++++++ src/vmwarexinerama.c | 38 ++++++++++++++++++++++++++++++++------ 2 files changed, 39 insertions(+), 6 deletions(-)
New commits: commit c9779cf7ef4589518f2a2ce97248f2dc14dc4767 Author: Julien Cristau <jcris...@debian.org> Date: Tue Oct 25 23:22:56 2011 +0200 Upload to unstable diff --git a/debian/changelog b/debian/changelog index ffe58a3..d6ecf81 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +xserver-xorg-video-vmware (1:11.0.3-3) unstable; urgency=high + + * Cherry-pick from upstream: Use dixLookupWindow instead of LookupWindow on + Xorg 1.5 & later. + + -- Julien Cristau <jcris...@debian.org> Tue, 25 Oct 2011 23:22:42 +0200 + xserver-xorg-video-vmware (1:11.0.3-2) unstable; urgency=low * Switch to dh: commit 40633644ea2b910a4faa9ff63b077f9100115aff Author: Alan Coopersmith <alan.coopersm...@oracle.com> Date: Tue Sep 27 19:31:22 2011 -0700 Use dixLookupWindow instead of LookupWindow on Xorg 1.5 & later The LookupWindow function was deprecated in xserver commit ed75b056511ccb4 and removed during the Xorg 1.11 merge window by commit 82a8677d9175732. Signed-off-by: Alan Coopersmith <alan.coopersm...@oracle.com> Signed-off-by: Thomas Hellstrom <thellst...@vmware.com> (cherry picked from commit 26845eb54a15d43f09288a87c5f74beac8fb6ec7) diff --git a/src/vmwarexinerama.c b/src/vmwarexinerama.c index 3476f43..d207f8f 100644 --- a/src/vmwarexinerama.c +++ b/src/vmwarexinerama.c @@ -48,6 +48,26 @@ #include <xf86_libc.h> #endif +/* + * LookupWindow was removed with video abi 11. + */ +#if (GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 4) +#ifndef DixGetAttrAccess +#define DixGetAttrAccess (1<<4) +#endif +#endif + +#if (GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 2) +static inline int +dixLookupWindow(WindowPtr *pWin, XID id, ClientPtr client, Mask access) +{ + *pWin = LookupWindow(id, client); + if (!*pWin) + return BadWindow; + return Success; +} +#endif + /* *---------------------------------------------------------------------------- @@ -116,10 +136,12 @@ VMwareXineramaGetState(ClientPtr client) ExtensionEntry *ext; ScrnInfoPtr pScrn; VMWAREPtr pVMWARE; + int rc; REQUEST_SIZE_MATCH(xPanoramiXGetStateReq); - pWin = LookupWindow(stuff->window, client); - if(!pWin) return BadWindow; + rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess); + if (rc != Success) + return rc; if (!(ext = CheckExtension(PANORAMIX_PROTOCOL_NAME))) { return BadMatch; @@ -168,10 +190,12 @@ VMwareXineramaGetScreenCount(ClientPtr client) ExtensionEntry *ext; ScrnInfoPtr pScrn; VMWAREPtr pVMWARE; + int rc; REQUEST_SIZE_MATCH(xPanoramiXGetScreenCountReq); - pWin = LookupWindow(stuff->window, client); - if(!pWin) return BadWindow; + rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess); + if (rc != Success) + return rc; if (!(ext = CheckExtension(PANORAMIX_PROTOCOL_NAME))) { return BadMatch; @@ -220,10 +244,12 @@ VMwareXineramaGetScreenSize(ClientPtr client) ExtensionEntry *ext; ScrnInfoPtr pScrn; VMWAREPtr pVMWARE; + int rc; REQUEST_SIZE_MATCH(xPanoramiXGetScreenSizeReq); - pWin = LookupWindow (stuff->window, client); - if(!pWin) return BadWindow; + rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess); + if (rc != Success) + return rc; if (!(ext = CheckExtension(PANORAMIX_PROTOCOL_NAME))) { return BadMatch; -- To UNSUBSCRIBE, email to debian-x-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/e1rioyn-0007a7...@vasks.debian.org