diff options
Diffstat (limited to 'xorg-server/dix/dispatch.c')
-rw-r--r-- | xorg-server/dix/dispatch.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/xorg-server/dix/dispatch.c b/xorg-server/dix/dispatch.c index b88f9744d..7d2d3b727 100644 --- a/xorg-server/dix/dispatch.c +++ b/xorg-server/dix/dispatch.c @@ -3743,6 +3743,8 @@ AddScreen(Bool (*pfnInit) (ScreenPtr /*pScreen */ , if (!pScreen) return -1; + dixInitScreenSpecificPrivates(pScreen); + if (!dixAllocatePrivates(&pScreen->devPrivates, PRIVATE_SCREEN)) { free(pScreen); return -1; @@ -3794,6 +3796,7 @@ AddScreen(Bool (*pfnInit) (ScreenPtr /*pScreen */ , screenInfo.screens[i] = pScreen; screenInfo.numScreens++; if (!(*pfnInit) (pScreen, argc, argv)) { + dixFreeScreenSpecificPrivates(pScreen); dixFreePrivates(pScreen->devPrivates, PRIVATE_SCREEN); free(pScreen); screenInfo.numScreens--; |