summaryrefslogtreecommitdiff
path: root/src/mesa/state_tracker/st_cb_syncobj.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/state_tracker/st_cb_syncobj.c')
-rw-r--r--src/mesa/state_tracker/st_cb_syncobj.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_cb_syncobj.c b/src/mesa/state_tracker/st_cb_syncobj.c
index 69a8678a7c..85aad08cc7 100644
--- a/src/mesa/state_tracker/st_cb_syncobj.c
+++ b/src/mesa/state_tracker/st_cb_syncobj.c
@@ -96,8 +96,8 @@ static void st_client_wait_sync(struct gl_context *ctx,
/* We don't care about GL_SYNC_FLUSH_COMMANDS_BIT, because flush is
* already called when creating a fence. */
- if (so->fence) {
- screen->fence_finish(screen, so->fence, 0);
+ if (so->fence &&
+ screen->fence_finish(screen, so->fence, 0, timeout) == 0) {
screen->fence_reference(screen, &so->fence, NULL);
so->b.StatusFlag = GL_TRUE;
}