summaryrefslogtreecommitdiffstats
path: root/control/zone.cpp
diff options
context:
space:
mode:
authorMatt Spinler <spinler@us.ibm.com>2018-04-25 15:26:10 -0500
committerMatthew Barth <msbarth@us.ibm.com>2018-05-09 10:15:35 -0500
commitba7b5fea818f65949cd074de9322094d3c54fb7b (patch)
tree953b30c25fa2086bd56f2af340965adbd8244f55 /control/zone.cpp
parent84f105b7f83bcafc28f3b9c30592cd754af44719 (diff)
downloadphosphor-fan-presence-ba7b5fea818f65949cd074de9322094d3c54fb7b.tar.gz
phosphor-fan-presence-ba7b5fea818f65949cd074de9322094d3c54fb7b.zip
Throw custom exceptions on D-Bus method failures
All 3 fan applications - control, monitor, and presence have cases where it is expected that a getProperty call may fail because a sensor is missing. While the applications already handle this, the InternalFailure exception that was being thrown by the underlying call generates log entries that make it look like something bad happened. The custom exceptions now being thrown do not log anything on creation, but store all of the failing information so that any callers could still log the info if they wanted to. Tested: Boot a water cooled Witherspoon and see the fan presence and monitor applications not look like they are failing. Boot a system without the fan hwmon running, and see fan-control-init still show the fails. Change-Id: Ifd8ad6e3deb492bbaf33f12c7258125dce1e5ea8 Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Diffstat (limited to 'control/zone.cpp')
-rw-r--r--control/zone.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/control/zone.cpp b/control/zone.cpp
index 325a5b8..f4c50d9 100644
--- a/control/zone.cpp
+++ b/control/zone.cpp
@@ -196,7 +196,7 @@ void Zone::setServices(const Group* group)
"NameHasOwner",
name);
}
- catch (const InternalFailure& ife)
+ catch (const util::DBusMethodError& e)
{
// Failed to get service name owner state
hasOwner = false;
OpenPOWER on IntegriCloud