Need to check pixmap priv before touch its field.
As now the pixmap may be allocated by DDX and doesn't have a valid pixmap private field. We must check pixmap private pointer before touch its field value. If a pixmap doesn't have a non-NULL private pointer, it doesn't have a valid FBO. Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
This commit is contained in:
parent
9264335347
commit
8a4758a358
|
@ -176,7 +176,7 @@ glamor_transform_boxes(BoxPtr boxes, int nbox, int dx, int dy)
|
|||
|
||||
|
||||
#define GLAMOR_PIXMAP_PRIV_IS_PICTURE(pixmap_priv) (pixmap_priv->is_picture == 1)
|
||||
#define GLAMOR_PIXMAP_PRIV_HAS_FBO(pixmap_priv) (pixmap_priv->gl_fbo == 1)
|
||||
#define GLAMOR_PIXMAP_PRIV_HAS_FBO(pixmap_priv) (pixmap_priv && pixmap_priv->gl_fbo == 1)
|
||||
|
||||
#define GLAMOR_PIXMAP_PRIV_NEED_VALIDATE(pixmap_priv) \
|
||||
(GLAMOR_PIXMAP_PRIV_HAS_FBO(pixmap_priv) \
|
||||
|
|
Loading…
Reference in New Issue
Block a user