From 99d1ba0519b313ab1306a33c7d0f7a0a1d6edb0a Mon Sep 17 00:00:00 2001 From: Patrick Venture Date: Thu, 21 Feb 2019 15:11:24 -0800 Subject: user_mgmt: drop c_str() when param is std::string Do not use c_str() when parameter is std::string. Caught via cppcheck. Change-Id: Iad7c1296d8be363df10ccf9278231187d7d29052 Signed-off-by: Patrick Venture --- user_channel/user_mgmt.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'user_channel/user_mgmt.cpp') diff --git a/user_channel/user_mgmt.cpp b/user_channel/user_mgmt.cpp index 42a1e09..a21da8c 100644 --- a/user_channel/user_mgmt.cpp +++ b/user_channel/user_mgmt.cpp @@ -656,8 +656,8 @@ ipmi_ret_t UserAccess::setUserEnabledState(const uint8_t userId, if (userInfo->userEnabled != enabledState) { std::string userPath = std::string(userObjBasePath) + "/" + userName; - setDbusProperty(bus, getUserServiceName().c_str(), userPath.c_str(), - usersInterface, userEnabledProperty, enabledState); + setDbusProperty(bus, getUserServiceName(), userPath, usersInterface, + userEnabledProperty, enabledState); } return IPMI_CC_OK; } @@ -693,8 +693,8 @@ ipmi_ret_t UserAccess::setUserPrivilegeAccess(const uint8_t userId, privAccess.privilege != userInfo->userPrivAccess[syncIndex].privilege) { std::string userPath = std::string(userObjBasePath) + "/" + userName; - setDbusProperty(bus, getUserServiceName().c_str(), userPath.c_str(), - usersInterface, userPrivProperty, priv); + setDbusProperty(bus, getUserServiceName(), userPath, usersInterface, + userPrivProperty, priv); } userInfo->userPrivAccess[chNum].privilege = privAccess.privilege; -- cgit v1.2.1