summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gallium/state_trackers/xa/xa_composite.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/xa/xa_composite.c b/src/gallium/state_trackers/xa/xa_composite.c
index 7ae35a160e5..c283a0d1892 100644
--- a/src/gallium/state_trackers/xa/xa_composite.c
+++ b/src/gallium/state_trackers/xa/xa_composite.c
@@ -472,6 +472,9 @@ xa_composite_prepare(struct xa_context *ctx,
struct xa_surface *dst_srf = comp->dst->srf;
int ret;
+ if (comp->mask && !comp->mask->srf)
+ return -XA_ERR_INVAL;
+
ret = xa_ctx_srf_create(ctx, dst_srf);
if (ret != XA_ERR_NONE)
return ret;