diff options
author | Otavio Salvador <otavio@ossystems.com.br> | 2009-05-22 20:40:16 -0300 |
---|---|---|
committer | Martin-Éric Racine <q-funk@iki.fi> | 2009-08-18 11:34:02 +0300 |
commit | b28abde0276ddd7f687242f3886f98b0e49a7fc2 (patch) | |
tree | ca7aa0509f11ef05d8e5860ec8fd42954a025373 | |
parent | 917a5bf5fdadac1a8799336aa8da2e51f8790eea (diff) |
Fix GX RandR to properly use dixSetPrivate.
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
-rw-r--r-- | src/gx_randr.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/gx_randr.c b/src/gx_randr.c index f61b522..e6701ac 100644 --- a/src/gx_randr.c +++ b/src/gx_randr.c @@ -58,18 +58,13 @@ typedef struct _GXRandRInfo #define AMD_OLDPRIV (GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 4) -#if AMD_OLDPRIV - static int GXRandRIndex; +#if AMD_OLDPRIV #define XF86RANDRINFO(p) ((XF86RandRInfoPtr) (p)->devPrivates[GXRandRIndex].ptr) #else - -static DevPrivateKey GXRandRKey; - #define XF86RANDRINFO(p) ((XF86RandRInfoPtr) \ - dixLookupPrivate(&(p)->devPrivates, GXRandRKey)); - + dixLookupPrivate(&(p)->devPrivates, GXRandRIndex)); #endif static int @@ -334,8 +329,6 @@ GXRandRInit(ScreenPtr pScreen, int rotation) } #if AMD_OLDPRIV GXRandRIndex = AllocateScreenPrivateIndex(); -#else - GXRandRKey = &GXRandRKey; #endif pRandr = xcalloc(sizeof(XF86RandRInfoRec), 1); @@ -364,7 +357,7 @@ GXRandRInit(ScreenPtr pScreen, int rotation) #if AMD_OLDPRIV pScreen->devPrivates[GXRandRIndex].ptr = pRandr; #else - dixSetPrivate(&pScreen->devPrivates, GXRandRKey, pRandr); + dixSetPrivate(&pScreen->devPrivates, &GXRandRIndex, pRandr); #endif return TRUE; } |