mirror of
https://github.com/CalcProgrammer1/OpenRGB.git
synced 2026-07-19 17:51:53 -04:00
Add error logs for non logged exceptions
This commit is contained in:
@@ -130,9 +130,10 @@ void DetectAsusAuraUSBMotherboards(hid_device_info* info, const std::string& /*n
|
||||
rgb_controller->name = "ASUS " + dmi.getMainboard();
|
||||
ResourceManager::get()->RegisterRGBController(rgb_controller);
|
||||
}
|
||||
catch(std::runtime_error&)
|
||||
catch(const std::runtime_error& ex)
|
||||
{
|
||||
// reading the config table failed
|
||||
LOG_ERROR("[AsusAuraUSB] An error occured while reading the config table: %s", ex.what());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
\*---------------------------------------------------------*/
|
||||
|
||||
#include "PhilipsHueController.h"
|
||||
#include "LogManager.h"
|
||||
|
||||
PhilipsHueController::PhilipsHueController(hueplusplus::Light light_ptr, std::string bridge_ip):light(light_ptr)
|
||||
{
|
||||
@@ -57,9 +58,9 @@ void PhilipsHueController::SetColor(unsigned char red, unsigned char green, unsi
|
||||
{
|
||||
light.setColorRGB(rgb, 0);
|
||||
}
|
||||
catch(std::exception& e)
|
||||
catch(const std::exception& e)
|
||||
{
|
||||
|
||||
LOG_ERROR("[PhilipsHueController] An error occured while setting the colors: %s", e.what());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -75,7 +76,7 @@ void PhilipsHueController::SetColor(unsigned char red, unsigned char green, unsi
|
||||
}
|
||||
catch(std::exception& e)
|
||||
{
|
||||
|
||||
LOG_ERROR("[PhilipsHueController] An error occured while setting the colors: %s", e.what());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -222,9 +222,9 @@ void DetectPhilipsHueControllers(std::vector<RGBController*>& rgb_controllers)
|
||||
}
|
||||
}
|
||||
}
|
||||
catch(std::exception &e)
|
||||
catch(const std::exception &e)
|
||||
{
|
||||
LOG_INFO("Exception occurred in Philips Hue detection");
|
||||
LOG_INFO("Exception occurred in Philips Hue detection: %s", e.what());
|
||||
}
|
||||
}
|
||||
} /* DetectPhilipsHueControllers() */
|
||||
|
||||
Reference in New Issue
Block a user