mirror of
https://github.com/X11Libre/xf86-video-ati.git
synced 2026-03-24 01:24:43 +00:00
glamor: Bail CreatePixmap on unsupported pixmap depth
Fixes crash in that case. Bugzilla: https://bugs.freedesktop.org/106293 Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
committed by
Michel Dänzer
parent
3dcfce8d0f
commit
65c9dfea4e
@@ -214,6 +214,9 @@ radeon_glamor_create_pixmap(ScreenPtr screen, int w, int h, int depth,
|
||||
struct radeon_pixmap *priv;
|
||||
PixmapPtr pixmap, new_pixmap = NULL;
|
||||
|
||||
if (!xf86GetPixFormat(scrn, depth))
|
||||
return NULL;
|
||||
|
||||
if (!RADEON_CREATE_PIXMAP_SHARED(usage)) {
|
||||
if (info->shadow_primary) {
|
||||
if (usage != CREATE_PIXMAP_USAGE_BACKING_PIXMAP)
|
||||
|
||||
Reference in New Issue
Block a user