diff options
author | Nicolai Hähnle <[email protected]> | 2017-10-22 17:38:42 +0200 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2017-11-09 11:53:20 +0100 |
commit | b650fc09c3a35ca624aad5fe4b5c34867708f116 (patch) | |
tree | 81a32b31057801dc1274d38489306205696e9f7d /src | |
parent | dd7c273e873f20474e2af1959ab2928292020941 (diff) |
radeonsi: fix potential use-after-free of debug callbacks
Found by inspection.
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_pipe.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c index 7940fc8d5b2..7c50ffae6a3 100644 --- a/src/gallium/drivers/radeonsi/si_pipe.c +++ b/src/gallium/drivers/radeonsi/si_pipe.c @@ -158,6 +158,10 @@ static void si_set_debug_callback(struct pipe_context *ctx, const struct pipe_debug_callback *cb) { struct si_context *sctx = (struct si_context *)ctx; + struct si_screen *screen = sctx->screen; + + util_queue_finish(&screen->shader_compiler_queue); + util_queue_finish(&screen->shader_compiler_queue_low_priority); if (cb) sctx->debug = *cb; |