diff options
-rw-r--r-- | dix/main.c | 1 | ||||
-rw-r--r-- | dix/privates.c | 9 |
2 files changed, 10 insertions, 0 deletions
diff --git a/dix/main.c b/dix/main.c index d7a9cdaae..549567660 100644 --- a/dix/main.c +++ b/dix/main.c @@ -339,6 +339,7 @@ dix_main(int argc, char *argv[], char *envp[]) for (i = screenInfo.numGPUScreens - 1; i >= 0; i--) { ScreenPtr pScreen = screenInfo.gpuscreens[i]; FreeScratchPixmapsForScreen(pScreen); + dixFreeScreenSpecificPrivates(pScreen); (*pScreen->CloseScreen) (pScreen); dixFreePrivates(pScreen->devPrivates, PRIVATE_SCREEN); free(pScreen); diff --git a/dix/privates.c b/dix/privates.c index e03b2255b..969d0141c 100644 --- a/dix/privates.c +++ b/dix/privates.c @@ -642,6 +642,15 @@ dixRegisterScreenSpecificPrivateKey(ScreenPtr pScreen, DevPrivateKey key, void dixFreeScreenSpecificPrivates(ScreenPtr pScreen) { + DevPrivateType t; + + for (t = PRIVATE_XSELINUX; t < PRIVATE_LAST; t++) { + DevPrivateKey key; + + for (key = pScreen->screenSpecificPrivates[t].key; key; key = key->next) { + key->initialized = FALSE; + } + } } /* Initialize screen-specific privates in AddScreen */ |