Skip to content

Commit

Permalink
steamcompmgr: Ensure forward progress for surfaces without windows wh…
Browse files Browse the repository at this point in the history
…en we discard commits

Otherwise they can get stuck in WaitForPresent, etc.
  • Loading branch information
misyltoad committed Sep 11, 2024
1 parent 861cf79 commit 99bed33
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/steamcompmgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6356,6 +6356,15 @@ void update_wayland_res(CommitDoneList_t *doneCommits, steamcompmgr_win_t *w, Re
wlserver_lock();
wlr_buffer_unlock( buf );
wlserver_unlock();

// Make sure to send the discarded event if we hit this
// to ensure forward progress.
if (!reslistentry.presentation_feedbacks.empty())
{
wlserver_presentation_feedback_discard( reslistentry.surf, reslistentry.presentation_feedbacks );
// presentation_feedbacks cleared by wlserver_presentation_feedback_discard
}

xwm_log.errorf( "waylandres but no win" );
return;
}
Expand Down

0 comments on commit 99bed33

Please sign in to comment.