From 0b02be925a29357f69abbc9e9a58e7c5aaed2eab Mon Sep 17 00:00:00 2001 From: Patrick Venture Date: Fri, 31 Aug 2018 11:55:55 -0700 Subject: add .clang-format Change-Id: I7c2a527b4751a560703a61fcbe9638b150546af5 Signed-off-by: Patrick Venture --- settings.cpp | 29 ++++++++++++----------------- 1 file changed, 12 insertions(+), 17 deletions(-) (limited to 'settings.cpp') diff --git a/settings.cpp b/settings.cpp index a1ca62c..770bde0 100644 --- a/settings.cpp +++ b/settings.cpp @@ -1,9 +1,11 @@ -#include -#include -#include "xyz/openbmc_project/Common/error.hpp" #include "settings.hpp" + #include "utils.hpp" +#include +#include +#include + namespace settings { @@ -15,14 +17,12 @@ constexpr auto mapperPath = "/xyz/openbmc_project/object_mapper"; constexpr auto mapperIntf = "xyz.openbmc_project.ObjectMapper"; Objects::Objects(sdbusplus::bus::bus& bus, - const std::vector& filter): + const std::vector& filter) : bus(bus) { auto depth = 0; - auto mapperCall = bus.new_method_call(mapperService, - mapperPath, - mapperIntf, + auto mapperCall = bus.new_method_call(mapperService, mapperPath, mapperIntf, "GetSubTree"); mapperCall.append(root); mapperCall.append(depth); @@ -66,10 +66,8 @@ Objects::Objects(sdbusplus::bus::bus& bus, Service Objects::service(const Path& path, const Interface& interface) const { using Interfaces = std::vector; - auto mapperCall = bus.new_method_call(mapperService, - mapperPath, - mapperIntf, - "GetObject"); + auto mapperCall = + bus.new_method_call(mapperService, mapperPath, mapperIntf, "GetObject"); mapperCall.append(path); mapperCall.append(Interfaces({interface})); @@ -118,12 +116,9 @@ std::tuple setting(const Objects& objects, const Path& oneTimeSetting = paths[index]; const Path& regularSetting = paths[!index]; - auto method = - objects.bus.new_method_call( - objects.service(oneTimeSetting, iface).c_str(), - oneTimeSetting.c_str(), - ipmi::PROP_INTF, - "Get"); + auto method = objects.bus.new_method_call( + objects.service(oneTimeSetting, iface).c_str(), oneTimeSetting.c_str(), + ipmi::PROP_INTF, "Get"); method.append(enabledIntf, "Enabled"); auto reply = objects.bus.call(method); if (reply.is_method_error()) -- cgit v1.2.1