aboutsummaryrefslogtreecommitdiff
path: root/src/strfnd.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/strfnd.h')
-rw-r--r--src/strfnd.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/strfnd.h b/src/strfnd.h
index bbd0fa1e0..2be92d43b 100644
--- a/src/strfnd.h
+++ b/src/strfnd.h
@@ -22,7 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include <string>
-std::string trim(std::string str);
+std::string trim(const std::string &str);
class Strfnd{
std::string tek;
@@ -74,8 +74,9 @@ public:
}
};
-inline std::string trim(std::string str)
+inline std::string trim(const std::string &s)
{
+ std::string str = s;
while(
str.length()>0
&&