summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-02-10 21:31:40 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-02-10 21:31:40 +0000
commit3681528e5a13c4e85b7276def209a2d6e73f4d2e (patch)
tree8be66fb0f0f4acb504dc2ad1a8658796a2141175 /src
parentbc47b88daf0552a83611514858ef6388350000b7 (diff)
Use userrec::MakeHost(), not strlcpy/strlcat!
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6568 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/commands.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/commands.cpp b/src/commands.cpp
index aa43685d4..15070abdf 100644
--- a/src/commands.cpp
+++ b/src/commands.cpp
@@ -103,7 +103,6 @@ long InspIRCd::Duration(const char* str)
bool InspIRCd::HostMatchesEveryone(const std::string &mask, userrec* user)
{
- char buffer[MAXBUF];
char itrigger[MAXBUF];
long matches = 0;
@@ -115,10 +114,7 @@ bool InspIRCd::HostMatchesEveryone(const std::string &mask, userrec* user)
for (user_hash::iterator u = clientlist->begin(); u != clientlist->end(); u++)
{
- strlcpy(buffer,u->second->ident,MAXBUF);
- charlcat(buffer,'@',MAXBUF);
- strlcat(buffer,u->second->host,MAXBUF);
- if (match(buffer,mask.c_str()))
+ if (match(u->second->MakeHost(),mask.c_str()),true)
matches++;
}
float percent = ((float)matches / (float)clientlist->size()) * 100;