Fixed errors reported by cppcheck 2.13.0 (#2400)

This commit is contained in:
Takeshi Nakatani
2024-01-25 00:46:45 +09:00
committed by GitHub
parent 2f9fb74a42
commit 54aa278df0
8 changed files with 14 additions and 14 deletions

View File

@ -124,7 +124,7 @@ std::string trim(std::string s, const char *t /* = SPACES */)
return trim_left(trim_right(std::move(s), t), t);
}
std::string peeloff(std::string s)
std::string peeloff(const std::string& s)
{
if(s.size() < 2 || *s.begin() != '"' || *s.rbegin() != '"'){
return s;