aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xwin/winallpriv.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/xwin/winallpriv.c')
-rw-r--r--xorg-server/hw/xwin/winallpriv.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/xorg-server/hw/xwin/winallpriv.c b/xorg-server/hw/xwin/winallpriv.c
index 6a6dc60db..f4078207e 100644
--- a/xorg-server/hw/xwin/winallpriv.c
+++ b/xorg-server/hw/xwin/winallpriv.c
@@ -72,7 +72,7 @@ winAllocatePrivates (ScreenPtr pScreen)
/* Intialize private structure members */
pScreenPriv->fActive = TRUE;
- /* Reserve screen memory for our privates */
+ /* Register our screen private */
if (!dixRegisterPrivateKey(g_iScreenPrivateKey, PRIVATE_SCREEN, 0))
{
ErrorF ("winAllocatePrivates - dixRegisterPrivateKey () failed\n");
@@ -162,6 +162,13 @@ winAllocateCmapPrivates (ColormapPtr pCmap)
/* Initialize the memory of the private structure */
ZeroMemory (pCmapPriv, sizeof (winPrivCmapRec));
+ /* Register our colourmap private */
+ if (!dixRegisterPrivateKey(g_iCmapPrivateKey, PRIVATE_COLORMAP, 0))
+ {
+ ErrorF ("winAllocateCmapPrivates - AllocateCmapPrivate () failed\n");
+ return FALSE;
+ }
+
/* Save the cmap private pointer */
winSetCmapPriv (pCmap, pCmapPriv);