[vlc-commits] hw: vaapi: chroma: fix uninitialized var usage
Thomas Guillem
git at videolan.org
Mon Jun 19 11:02:51 CEST 2017
vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Mon Jun 19 11:01:58 2017 +0200| [c47357123ee690e764af0ea8d22598e5e97eaf34] | committer: Thomas Guillem
hw: vaapi: chroma: fix uninitialized var usage
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c47357123ee690e764af0ea8d22598e5e97eaf34
---
modules/hw/vaapi/chroma.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/modules/hw/vaapi/chroma.c b/modules/hw/vaapi/chroma.c
index 771feb5c3a..278ecf9e17 100644
--- a/modules/hw/vaapi/chroma.c
+++ b/modules/hw/vaapi/chroma.c
@@ -309,6 +309,7 @@ static int Open(vlc_object_t *obj)
}
filter_sys->derive_failed = false;
filter_sys->image_fallback_failed = false;
+ filter_sys->image_fallback.image_id = VA_INVALID_ID;
if (is_upload)
{
@@ -359,7 +360,7 @@ Close(vlc_object_t *obj)
{
filter_sys_t *const filter_sys = ((filter_t *)obj)->p_sys;
- if (filter_sys->image_fallback.image_id)
+ if (filter_sys->image_fallback.image_id != VA_INVALID_ID)
vlc_vaapi_DestroyImage(obj, filter_sys->dpy,
filter_sys->image_fallback.image_id);
if (filter_sys->dest_pics)
More information about the vlc-commits
mailing list