]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
src/log/Entry.h: pass function parameter by reference
authorDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Thu, 7 Feb 2013 19:07:52 +0000 (20:07 +0100)
committerDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Mon, 11 Feb 2013 10:38:02 +0000 (11:38 +0100)
Fix "(performance) Function parameter 's' should be passed by reference."
from cppchecker.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
src/log/Entry.h

index 7f6b1499f9d34d71bad6e153ebaf467e1bdeaf62..7cdf11612acbf01b0c92fbacf78cd71abdfc9c07 100644 (file)
@@ -40,7 +40,7 @@ struct Entry {
     }
   }
 
-  void set_str(const std::string s) {
+  void set_str(const std::string &s) {
     ostream os(&m_streambuf);
     os << s;
   }