diff options
author | Patrick Venture <venture@google.com> | 2018-10-14 14:11:30 -0700 |
---|---|---|
committer | Patrick Venture <venture@google.com> | 2018-10-14 14:12:50 -0700 |
commit | f287059d29d5307309ff2a84f487b9f9b56b5160 (patch) | |
tree | 08ec25ed9649a4b58c3642060a1eb9cf4422c988 | |
parent | 6425ab76f5bdde1ea098645acc3b578414406f4f (diff) | |
download | phosphor-state-manager-f287059d29d5307309ff2a84f487b9f9b56b5160.tar.gz phosphor-state-manager-f287059d29d5307309ff2a84f487b9f9b56b5160.zip |
discover_system_state: const reference for params
[discover_system_state.cpp:93]: (performance) Function parameter 'value'
should be passed by const reference.
Change-Id: I25fd43f7993d4d2d94731dbd8d9f490623933d6b
Signed-off-by: Patrick Venture <venture@google.com>
-rw-r--r-- | discover_system_state.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/discover_system_state.cpp b/discover_system_state.cpp index dfbf876..5ce94b4 100644 --- a/discover_system_state.cpp +++ b/discover_system_state.cpp @@ -89,8 +89,9 @@ std::string getProperty(sdbusplus::bus::bus& bus, std::string path, return sdbusplus::message::variant_ns::get<std::string>(property); } -void setProperty(sdbusplus::bus::bus& bus, std::string path, - std::string interface, std::string property, std::string value) +void setProperty(sdbusplus::bus::bus& bus, const std::string& path, + const std::string& interface, const std::string& property, + const std::string& value) { sdbusplus::message::variant<std::string> variantValue = value; std::string service = getService(bus, path, interface); |