~vanvugt/mir/fix-1662044

« back to all changes in this revision

Viewing changes to src/client/presentation_chain.cpp

  • Committer: Tarmac
  • Author(s): Kevin DuBois
  • Date: 2017-02-03 17:46:55 UTC
  • mfrom: (4010.1.2 blank-nested)
  • Revision ID: tarmac-20170203174655-c0s0p3ozpkfvy9kf
add missing check for wait handle when configuring swapinterval.

Fixes: LP: #1661508. Fixes: https://bugs.launchpad.net/bugs/1661508.

Approved by Cemil Azizoglu, mir-ci-bot.

Show diffs side-by-side

added added

removed removed

Lines of Context:
87
87
 
88
88
void mcl::PresentationChain::set_dropping_mode()
89
89
{
90
 
    interval_config.set_swap_interval(0)->wait_for_all();
 
90
    if (auto wh = interval_config.set_swap_interval(0))
 
91
        wh->wait_for_all();
91
92
}
92
93
 
93
94
void mcl::PresentationChain::set_queueing_mode()
94
95
{
95
 
    interval_config.set_swap_interval(1)->wait_for_all();
 
96
    if (auto wh = interval_config.set_swap_interval(1))
 
97
        wh->wait_for_all();
96
98
}