glamor: check for non NULL pixmap at close_screen
DDX such as Xorg, Xwayland & Xephyr do not destroy the pixmap before they call into CloseScreen. At the same time Xvfb (support for glamor coming with later commit) do. As such the pixmap will be NULL and we'll crash out. Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
This commit is contained in:
parent
7667180fb9
commit
744c419cb4
|
@ -927,7 +927,11 @@ glamor_close_screen(ScreenPtr screen)
|
|||
ps->Glyphs = glamor_priv->saved_procs.glyphs;
|
||||
|
||||
screen_pixmap = screen->GetScreenPixmap(screen);
|
||||
glamor_pixmap_destroy_fbo(screen_pixmap);
|
||||
/* For DDX like Xwayland and Xorg, the pixmap is not destroyed so
|
||||
* we should do so here.
|
||||
*/
|
||||
if (screen_pixmap)
|
||||
glamor_pixmap_destroy_fbo(screen_pixmap);
|
||||
|
||||
glamor_release_screen_priv(screen);
|
||||
|
||||
|
|
Loading…
Reference in New Issue