rbug: Fix rbug_delete_vs_state lock acquisition.

Fix warning reported by Coverity Scan.

Double unlock (LOCK)
double_unlock: mtx_unlock unlocks rb_pipe->call_mutex while it is
unlocked.

Fixes: 07838ff990 ("rbug: Use the call mutex")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3023
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Jakob Bornecrantz <jakob@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5196>
This commit is contained in:
Vinson Lee
2020-05-24 15:40:39 -07:00
committed by Marge Bot
parent 583d7d3d8d
commit c0c03f4772

View File

@@ -490,7 +490,7 @@ rbug_delete_vs_state(struct pipe_context *_pipe,
struct rbug_context *rb_pipe = rbug_context(_pipe);
struct rbug_shader *rb_shader = rbug_shader(_vs);
mtx_unlock(&rb_pipe->call_mutex);
mtx_lock(&rb_pipe->call_mutex);
rbug_shader_destroy(rb_pipe, rb_shader);
mtx_unlock(&rb_pipe->call_mutex);
}