diff options
Diffstat (limited to 'randr/randr.c')
-rw-r--r-- | randr/randr.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/randr/randr.c b/randr/randr.c index ffb34d6a9..f52a46ac8 100644 --- a/randr/randr.c +++ b/randr/randr.c @@ -54,11 +54,9 @@ static int SProcRRDispatch (ClientPtr pClient); int RREventBase; int RRErrorBase; RESTYPE RRClientType, RREventType; /* resource types for event masks */ -static int RRClientPrivateKeyIndex; -DevPrivateKey RRClientPrivateKey = &RRClientPrivateKeyIndex; +DevPrivateKeyRec RRClientPrivateKeyRec; -static int rrPrivKeyIndex; -DevPrivateKey rrPrivKey = &rrPrivKeyIndex; +DevPrivateKeyRec rrPrivKeyRec; static void RRClientCallback (CallbackListPtr *list, @@ -215,6 +213,9 @@ Bool RRInit (void) return FALSE; RRGeneration = serverGeneration; } + if (!dixRegisterPrivateKey(&rrPrivKeyRec, PRIVATE_SCREEN, 0)) + return FALSE; + return TRUE; } @@ -329,9 +330,9 @@ RRExtensionInit (void) if (RRNScreens == 0) return; - if (!dixRequestPrivate(RRClientPrivateKey, - sizeof (RRClientRec) + - screenInfo.numScreens * sizeof (RRTimesRec))) + if (!dixRegisterPrivateKey(&RRClientPrivateKeyRec, PRIVATE_CLIENT, + sizeof (RRClientRec) + + screenInfo.numScreens * sizeof (RRTimesRec))) return; if (!AddCallback (&ClientStateCallback, RRClientCallback, 0)) return; |