freedreno: fix fence-fd leak
sync_accumulate() does not take ownership.
Fixes: bf23ff83e6
("freedreno: fence_server_sync() fixes")
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6692>
This commit is contained in:
@@ -519,6 +519,7 @@ fd_context_switch_to(struct fd_context *ctx, struct fd_batch *batch)
|
||||
{
|
||||
if (ctx->in_fence_fd != -1) {
|
||||
sync_accumulate("freedreno", &batch->in_fence_fd, ctx->in_fence_fd);
|
||||
close(ctx->in_fence_fd);
|
||||
ctx->in_fence_fd = -1;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user