ControllerInterface: Make UpdateInput / UpdateOutput return void

The return values here have never been checked, so it doesn't make sense
to return a value to begin with.
This commit is contained in:
Jasper St. Pierre
2014-11-13 00:55:14 -08:00
parent 61fcfc4bf2
commit f2787f620e
19 changed files with 35 additions and 76 deletions

View File

@ -135,22 +135,15 @@ void ControllerInterface::Shutdown()
//
// Update input for all devices, return true if all devices returned successful
//
bool ControllerInterface::UpdateInput()
void ControllerInterface::UpdateInput()
{
std::unique_lock<std::recursive_mutex> lk(update_lock, std::defer_lock);
if (!lk.try_lock())
return false;
size_t ok_count = 0;
return;
for (ciface::Core::Device* d : m_devices)
{
if (d->UpdateInput())
++ok_count;
}
return (m_devices.size() == ok_count);
d->UpdateInput();
}
//
@ -158,22 +151,15 @@ bool ControllerInterface::UpdateInput()
//
// Update output for all devices, return true if all devices returned successful
//
bool ControllerInterface::UpdateOutput()
void ControllerInterface::UpdateOutput()
{
std::unique_lock<std::recursive_mutex> lk(update_lock, std::defer_lock);
if (!lk.try_lock())
return false;
size_t ok_count = 0;
return;
for (ciface::Core::Device* d : m_devices)
{
if (d->UpdateOutput())
++ok_count;
}
return (m_devices.size() == ok_count);
d->UpdateOutput();
}
//