diff options
author | Xiang, Haihao <haihao.xiang@intel.com> | 2013-07-18 13:13:31 +0800 |
---|---|---|
committer | Xiang, Haihao <haihao.xiang@intel.com> | 2014-06-26 22:05:32 +0800 |
commit | c61d8c6ce9ffc27320e9e177c1e1123d5f1b5014 (patch) | |
tree | b5b705ba7f3222ea0db5393eebdee95b5ebd862b /va | |
parent | ce3315accf067115fbe22a13bf8689bab01da778 (diff) | |
download | libva-c61d8c6ce9ffc27320e9e177c1e1123d5f1b5014.tar.gz |
va: release VADisplayContext at the end of vaTerminate()
Otherwise it will result in invalid reading in va_TraceEnd()
Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com>
(cherry picked from commit d4988142a3f2256e38c5c5cdcdfc1b4f5f3c1ea9)
Tested-by: Daniel Charles <daniel.charles@intel.com> on ChromiumOS
Diffstat (limited to 'va')
-rw-r--r-- | va/va.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -515,15 +515,15 @@ VAStatus vaTerminate ( free(old_ctx->vtable_vpp); old_ctx->vtable_vpp = NULL; - if (VA_STATUS_SUCCESS == vaStatus) - pDisplayContext->vaDestroy(pDisplayContext); - VA_TRACE_LOG(va_TraceTerminate, dpy); va_TraceEnd(dpy); va_FoolEnd(dpy); + if (VA_STATUS_SUCCESS == vaStatus) + pDisplayContext->vaDestroy(pDisplayContext); + return vaStatus; } |