summaryrefslogtreecommitdiff
path: root/src/hashcomp.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/hashcomp.cpp')
-rw-r--r--src/hashcomp.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/hashcomp.cpp b/src/hashcomp.cpp
index f1d0f0678..32f74475f 100644
--- a/src/hashcomp.cpp
+++ b/src/hashcomp.cpp
@@ -414,14 +414,16 @@ int irc::modestacker::GetStackedLine(std::vector<std::string> &result, int max_l
return n;
}
-irc::stringjoiner::stringjoiner(const std::vector<std::string>& sequence)
+std::string irc::stringjoiner(const std::vector<std::string>& sequence, char separator)
{
+ std::string joined;
if (sequence.empty())
- return; // nothing to do here
+ return joined; // nothing to do here
for (std::vector<std::string>::const_iterator i = sequence.begin(); i != sequence.end(); ++i)
- joined.append(*i).push_back(' ');
+ joined.append(*i).push_back(separator);
joined.erase(joined.end()-1);
+ return joined;
}
irc::portparser::portparser(const std::string &source, bool allow_overlapped)