Start using .clang-format
Used the one from docs/style/cpp.
Change-Id: I3bdc2b353bf18a437266b362d8205b8463a9ce2b
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
diff --git a/utility.cpp b/utility.cpp
index ac614d4..e9918bb 100644
--- a/utility.cpp
+++ b/utility.cpp
@@ -28,15 +28,11 @@
using namespace phosphor::logging;
-
-std::string getService(const std::string& path,
- const std::string& interface,
+std::string getService(const std::string& path, const std::string& interface,
sdbusplus::bus::bus& bus)
{
- auto method = bus.new_method_call(MAPPER_BUSNAME,
- MAPPER_PATH,
- MAPPER_INTERFACE,
- "GetObject");
+ auto method = bus.new_method_call(MAPPER_BUSNAME, MAPPER_PATH,
+ MAPPER_INTERFACE, "GetObject");
method.append(path);
method.append(std::vector<std::string>({interface}));
@@ -45,8 +41,8 @@
if (reply.is_method_error())
{
log<level::ERR>("Error in mapper call to get service name",
- entry("PATH=%s", path.c_str()),
- entry("INTERFACE=%s", interface.c_str()));
+ entry("PATH=%s", path.c_str()),
+ entry("INTERFACE=%s", interface.c_str()));
// TODO openbmc/openbmc#851 - Once available, throw returned error
throw std::runtime_error("Error in mapper call to get service name");
@@ -57,16 +53,15 @@
if (response.empty())
{
- log<level::ERR>(
- "Error in mapper response for getting service name",
- entry("PATH=%s", path.c_str()),
- entry("INTERFACE=%s", interface.c_str()));
+ log<level::ERR>("Error in mapper response for getting service name",
+ entry("PATH=%s", path.c_str()),
+ entry("INTERFACE=%s", interface.c_str()));
return std::string{};
}
return response.begin()->first;
}
-}
-}
-}
+} // namespace util
+} // namespace power
+} // namespace witherspoon