summaryrefslogtreecommitdiff
path: root/src/qxl_driver.c
diff options
context:
space:
mode:
authorSøren Sandmann <ssp@localhost.localdomain>2010-11-11 08:38:37 -0500
committerSøren Sandmann <ssp@localhost.localdomain>2010-11-11 08:38:37 -0500
commit6768b98ddb393eee9a43467ae0db1dcf17af57fe (patch)
tree3f63108272f59e5b9302b57561e31dbe8575d214 /src/qxl_driver.c
parentf9b4f5a03d8db0f1768dd495afbd5a4259c94543 (diff)
Don't unmap memory until after uxa_close_screen; allow surface creation without vtSema
Diffstat (limited to 'src/qxl_driver.c')
-rw-r--r--src/qxl_driver.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/qxl_driver.c b/src/qxl_driver.c
index 4dc362b..226c331 100644
--- a/src/qxl_driver.c
+++ b/src/qxl_driver.c
@@ -312,12 +312,6 @@ qxl_close_screen(int scrnIndex, ScreenPtr pScreen)
qxl_screen_t *qxl = pScrn->driverPrivate;
Bool result;
- if (pScrn->vtSema) {
- qxl_restore_state(pScrn);
- qxl_unmap_memory(qxl, scrnIndex);
- }
- pScrn->vtSema = FALSE;
-
ErrorF ("Freeing %p\n", qxl->fb);
free(qxl->fb);
qxl->fb = NULL;
@@ -329,6 +323,12 @@ qxl_close_screen(int scrnIndex, ScreenPtr pScreen)
result = pScreen->CloseScreen(scrnIndex, pScreen);
+ if (pScrn->vtSema) {
+ qxl_restore_state(pScrn);
+ qxl_unmap_memory(qxl, scrnIndex);
+ }
+ pScrn->vtSema = FALSE;
+
return result;
}