diff --git a/0001-i965_drv_video-make-VADriverContext.vtable-a-pointer.patch b/0001-i965_drv_video-make-VADriverContext.vtable-a-pointer.patch index 7d6b8d3..3891221 100644 --- a/0001-i965_drv_video-make-VADriverContext.vtable-a-pointer.patch +++ b/0001-i965_drv_video-make-VADriverContext.vtable-a-pointer.patch @@ -1,7 +1,7 @@ From 2b7850b35a51c59a6692781d5e40e4bb608b6344 Mon Sep 17 00:00:00 2001 From: Gwenole Beauchesne Date: Thu, 27 Jan 2011 10:41:24 +0100 -Subject: [PATCH] i965_drv_video: make VADriverContext.vtable a pointer. +Subject: [PATCH 1/2] i965_drv_video: make VADriverContext.vtable a pointer. --- i965_drv_video/i965_drv_video.c | 85 ++++++++++++++++++++------------------- @@ -111,5 +111,5 @@ index 303e090..5baa0ff 100644 i965 = (struct i965_driver_data *)calloc(1, sizeof(*i965)); assert(i965); -- -1.7.3.4 +1.7.4.1 diff --git a/0002-i965_dri_video-don-t-try-to-render-an-invalid-surfac.patch b/0002-i965_dri_video-don-t-try-to-render-an-invalid-surfac.patch new file mode 100644 index 0000000..508710e --- /dev/null +++ b/0002-i965_dri_video-don-t-try-to-render-an-invalid-surfac.patch @@ -0,0 +1,26 @@ +From 3739a5e19700f508eac0b874856d08a06ea9ff45 Mon Sep 17 00:00:00 2001 +From: Xiang, Haihao +Date: Thu, 24 Feb 2011 15:22:46 +0800 +Subject: [PATCH 2/2] i965_dri_video: don't try to render an invalid surface + +Signed-off-by: Xiang, Haihao +--- + i965_drv_video/i965_drv_video.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/i965_drv_video/i965_drv_video.c b/i965_drv_video/i965_drv_video.c +index 5baa0ff..0f09d8a 100644 +--- a/i965_drv_video/i965_drv_video.c ++++ b/i965_drv_video/i965_drv_video.c +@@ -1736,7 +1736,7 @@ i965_PutSurface(VADriverContextP ctx, + * will get here + */ + obj_surface = SURFACE(surface); +- if (obj_surface->bo == NULL) ++ if (!obj_surface || !obj_surface->bo) + return VA_STATUS_SUCCESS; + + dri_drawable = dri_get_drawable(ctx, (Drawable)draw); +-- +1.7.4.1 + diff --git a/libva.changes b/libva.changes index 96aee8f..5eff522 100644 --- a/libva.changes +++ b/libva.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Mar 3 15:02:06 UTC 2011 - kkhere.geo@gmail.com + +- patch: i965_dri_video: don't try to render an invalid surface + ------------------------------------------------------------------- Tue Feb 15 12:05:12 UTC 2011 - kkhere.geo@gmail.com diff --git a/libva.spec b/libva.spec index a1b729a..d64c46f 100644 --- a/libva.spec +++ b/libva.spec @@ -7,6 +7,7 @@ Url: http://freedesktop.org/wiki/Software/vaapi Group: System/Libraries Source: http://cgit.freedesktop.org/libva/snapshot/%{name}-%{version}.tar.bz2 Patch1: 0001-i965_drv_video-make-VADriverContext.vtable-a-pointer.patch +Patch2: 0002-i965_dri_video-don-t-try-to-render-an-invalid-surfac.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: pkg-config libudev-devel BuildRequires: xorg-x11-devel xorg-x11-libXext-devel xorg-x11-libXfixes-devel @@ -49,6 +50,7 @@ This package provides the development environment for libva. %prep %setup -q %patch1 -p1 +%patch2 -p1 %build autoreconf -v --install