From 5328c8001b26b5a341edaec3618919dd8a4de52f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Christian=20K=C3=B6nig?= Date: Thu, 23 May 2013 19:31:08 +0200 Subject: [PATCH] st/vdpau: destroy handle table only when it's empty MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Christian König --- src/gallium/state_trackers/vdpau/htab.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/vdpau/htab.c b/src/gallium/state_trackers/vdpau/htab.c index 39ff7be3786..8b809f2cb5e 100644 --- a/src/gallium/state_trackers/vdpau/htab.c +++ b/src/gallium/state_trackers/vdpau/htab.c @@ -55,7 +55,7 @@ void vlDestroyHTAB(void) { #ifdef VL_HANDLES pipe_mutex_lock(htab_lock); - if (htab) { + if (htab && !handle_table_get_first_handle(htab)) { handle_table_destroy(htab); htab = NULL; } -- 2.30.2