diff --git a/demos/gears.c b/demos/gears.c index f7b8cada..72916dc7 100644 --- a/demos/gears.c +++ b/demos/gears.c @@ -218,7 +218,8 @@ static void cxg_wait_for_previous_frame(struct cx_gears *cxg) if (ID3D12Fence_GetCompletedValue(fence->fence) < v) { - ID3D12Fence_SetEventOnCompletion(fence->fence, v, fence->event); + hr = ID3D12Fence_SetEventOnCompletion(fence->fence, v, fence->event); + assert(SUCCEEDED(hr)); demo_wait_event(fence->event, INFINITE); } diff --git a/demos/triangle.c b/demos/triangle.c index 15f348f6..96ad8379 100644 --- a/demos/triangle.c +++ b/demos/triangle.c @@ -142,7 +142,8 @@ static void cxt_wait_for_previous_frame(struct cx_triangle *cxt) if (ID3D12Fence_GetCompletedValue(fence->fence) < v) { - ID3D12Fence_SetEventOnCompletion(fence->fence, v, fence->event); + hr = ID3D12Fence_SetEventOnCompletion(fence->fence, v, fence->event); + assert(SUCCEEDED(hr)); demo_wait_event(fence->event, INFINITE); }