From 06b1b875ba13227ddaf7f28dbdcdaa3eb49f0857 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Wed, 6 Jun 2012 17:05:13 +0100 Subject: [PATCH] uxa/i915: check for failure to allocate temporary destination If the target drawable is too large for the render pipeline, we need to create a temporary surface. This may fail, so abort if it does. Reported-by: Zdenek Kabelac Signed-off-by: Chris Wilson --- src/i915_video.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/i915_video.c b/src/i915_video.c index c73615e6..ae2e6bb5 100644 --- a/src/i915_video.c +++ b/src/i915_video.c @@ -74,6 +74,8 @@ I915DisplayVideoTextured(ScrnInfoPtr scrn, dstRegion->extents.y2 - dyo, pixmap->drawable.depth, CREATE_PIXMAP_USAGE_SCRATCH); + if (target == NULL) + return; pix_xoff = -dxo; pix_yoff = -dyo;