Limit variable scope

This commit is contained in:
practicalswift
2017-06-04 22:45:22 +02:00
parent f259263a7b
commit 90593ed92c
11 changed files with 21 additions and 23 deletions

View File

@@ -402,12 +402,12 @@ BOOST_AUTO_TEST_CASE(test_CheckQueueControl_Locks)
{
boost::thread_group tg;
std::mutex m;
bool has_lock {false};
bool has_tried {false};
bool done {false};
bool done_ack {false};
std::condition_variable cv;
{
bool has_lock {false};
bool has_tried {false};
bool done {false};
bool done_ack {false};
std::unique_lock<std::mutex> l(m);
tg.create_thread([&]{
CCheckQueueControl<FakeCheck> control(queue.get());