diff --git a/device/device.cpp b/device/device.cpp index ee16c3a..207551d 100644 --- a/device/device.cpp +++ b/device/device.cpp @@ -254,7 +254,7 @@ bool Device::open(OpenFlags flags, OpenStatusHandler handler) { // otherwise quiet stream. This lock makes sure suppressDisconnects() will // block until we've either gotten our status update or disconnected from // the device. - std::lock_guard lk(heartbeatMutex); + std::lock_guard lk(heartbeatMutex); if(heartbeatSuppressed()) continue; @@ -679,9 +679,9 @@ optional Device::getAnalogIO(IO type, size_t number /* = 1 */) { } Lifetime Device::suppressDisconnects() { - std::lock_guard lk(heartbeatMutex); + std::lock_guard lk(heartbeatMutex); heartbeatSuppressedByUser++; - return Lifetime([this] { std::lock_guard lk2(heartbeatMutex); heartbeatSuppressedByUser--; }); + return Lifetime([this] { std::lock_guard lk2(heartbeatMutex); heartbeatSuppressedByUser--; }); } void Device::addExtension(std::shared_ptr&& extension) {