]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
str_list: str_join() pass param by reference 18509/head
authorKefu Chai <kchai@redhat.com>
Mon, 23 Oct 2017 04:26:42 +0000 (12:26 +0800)
committerKefu Chai <kchai@redhat.com>
Tue, 24 Oct 2017 08:06:26 +0000 (16:06 +0800)
Signed-off-by: Kefu Chai <kchai@redhat.com>
src/include/str_list.h

index 8ca07f3d31bb6bfa12494580ac261e28610e117a..9c782d4adf9a4b74791cc7254bdd150dde950c70 100644 (file)
@@ -77,7 +77,7 @@ extern void get_str_set(const std::string& str,
  * @param [in] sep String used to join each element from **v**
  * @return empty string if **v** is empty or concatenated string
 **/
-inline std::string str_join(const std::vector<std::string>& v, std::string sep)
+inline std::string str_join(const std::vector<std::string>& v, const std::string& sep)
 {
   if (v.empty())
     return std::string();