summaryrefslogtreecommitdiff
path: root/exa/exa.c
diff options
context:
space:
mode:
Diffstat (limited to 'exa/exa.c')
-rw-r--r--exa/exa.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/exa/exa.c b/exa/exa.c
index ba063bb04..496b89864 100644
--- a/exa/exa.c
+++ b/exa/exa.c
@@ -41,6 +41,8 @@ static int exaScreenPrivateKeyIndex;
DevPrivateKey exaScreenPrivateKey = &exaScreenPrivateKeyIndex;
static int exaPixmapPrivateKeyIndex;
DevPrivateKey exaPixmapPrivateKey = &exaPixmapPrivateKeyIndex;
+static int exaGCPrivateKeyIndex;
+DevPrivateKey exaGCPrivateKey = &exaGCPrivateKeyIndex;
#ifdef MITSHM
static ShmFuncs exaShmFuncs = { NULL, NULL };
@@ -661,6 +663,8 @@ static GCFuncs exaGCFuncs = {
static int
exaCreateGC (GCPtr pGC)
{
+ ExaGCPriv(pGC);
+
if (!fbCreateGC (pGC))
return FALSE;
@@ -890,6 +894,13 @@ exaDriverInit (ScreenPtr pScreen,
exaDDXDriverInit(pScreen);
+ if (!dixRequestPrivate(exaGCPrivateKey, sizeof(ExaGCPrivRec))) {
+ LogMessage(X_WARNING,
+ "EXA(%d): Failed to allocate GC private\n",
+ pScreen->myNum);
+ return FALSE;
+ }
+
/*
* Replace various fb screen functions
*/