diff options
author | Naushir Patuck <naush@raspberrypi.com> | 2022-07-27 09:55:22 +0100 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2022-07-27 18:12:18 +0300 |
commit | 8757cc7c4291420e94047ea54a735cbaa1eb6adb (patch) | |
tree | 56da27fd7f8d537a7cf8c6f26564654ce32e85a7 /src/ipa/raspberrypi/controller/rpi/ccm.cpp | |
parent | f95bae418c0c606903027322e37ece22b52d3c36 (diff) |
ipa: raspberryip: Remove all exception throw statements
Replace all exception throw statements with LOG(RPi*, Fatal) error messages.
Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src/ipa/raspberrypi/controller/rpi/ccm.cpp')
-rw-r--r-- | src/ipa/raspberrypi/controller/rpi/ccm.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/ipa/raspberrypi/controller/rpi/ccm.cpp b/src/ipa/raspberrypi/controller/rpi/ccm.cpp index 8095c42d..cf0c85d2 100644 --- a/src/ipa/raspberrypi/controller/rpi/ccm.cpp +++ b/src/ipa/raspberrypi/controller/rpi/ccm.cpp @@ -45,11 +45,11 @@ void Matrix::read(boost::property_tree::ptree const ¶ms) int n = 0; for (auto it = params.begin(); it != params.end(); it++) { if (n++ == 9) - throw std::runtime_error("Ccm: too many values in CCM"); + LOG(RPiCcm, Fatal) << "Ccm: too many values in CCM"; *ptr++ = it->second.get_value<double>(); } if (n < 9) - throw std::runtime_error("Ccm: too few values in CCM"); + LOG(RPiCcm, Fatal) << "Ccm: too few values in CCM"; } Ccm::Ccm(Controller *controller) @@ -70,12 +70,11 @@ void Ccm::read(boost::property_tree::ptree const ¶ms) ctCcm.ccm.read(p.second.get_child("ccm")); if (!config_.ccms.empty() && ctCcm.ct <= config_.ccms.back().ct) - throw std::runtime_error( - "Ccm: CCM not in increasing colour temperature order"); + LOG(RPiCcm, Fatal) << "Ccm: CCM not in increasing colour temperature order"; config_.ccms.push_back(std::move(ctCcm)); } if (config_.ccms.empty()) - throw std::runtime_error("Ccm: no CCMs specified"); + LOG(RPiCcm, Fatal) << "Ccm: no CCMs specified"; } void Ccm::setSaturation(double saturation) |