summaryrefslogtreecommitdiff
path: root/src/protocol/unreal32.c
diff options
context:
space:
mode:
authorcyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864>2010-01-04 06:40:24 +0000
committercyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864>2010-01-04 06:40:24 +0000
commitb462814760cb7c0830072275acc97291a9fb905b (patch)
tree56cfe6caee408eb852f728cd8aaa2d18e4365228 /src/protocol/unreal32.c
parent2708eea5d13c249143b83fbaa8b552992f0ac8b6 (diff)
Changed 'char *' fields in BotInfo to 'std::string', cleanup of bots.cpp, changed many other functions to use 'const std::string &' arguments as a chain reaction.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2733 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/protocol/unreal32.c')
-rw-r--r--src/protocol/unreal32.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/protocol/unreal32.c b/src/protocol/unreal32.c
index 81229930c..00335bbbb 100644
--- a/src/protocol/unreal32.c
+++ b/src/protocol/unreal32.c
@@ -234,11 +234,10 @@ class UnrealIRCdProto : public IRCDProto
send_cmd(bi ? bi->nick : Config.ServerName, "v %s %s", u->nick.c_str(), buf);
}
- void SendClientIntroduction(const char *nick, const char *user, const char *host, const char *real, const char *modes, const char *uid)
+ void SendClientIntroduction(const std::string &nick, const std::string &user, const std::string &host, const std::string &real, const char *modes, const std::string &uid)
{
EnforceQlinedNick(nick, Config.s_BotServ);
- send_cmd(NULL, "& %s 1 %ld %s %s %s 0 %s %s%s :%s", nick, static_cast<long>(time(NULL)), user, host, Config.ServerName, modes, host,
- myIrcd->nickip ? " *" : " ", real);
+ send_cmd(NULL, "& %s 1 %ld %s %s %s 0 %s %s%s :%s", nick.c_str(), static_cast<long>(time(NULL)), user.c_str(), host.c_str(), Config.ServerName, modes, host.c_str(), myIrcd->nickip ? " *" : " ", real.c_str());
SendSQLine(nick, "Reserved for services");
}
@@ -267,17 +266,18 @@ class UnrealIRCdProto : public IRCDProto
/* JOIN */
void SendJoin(BotInfo *user, const char *channel, time_t chantime)
{
- send_cmd(Config.ServerName, "~ !%s %s :%s", base64enc(static_cast<long>(chantime)), channel, user->nick);
+ send_cmd(Config.ServerName, "~ !%s %s :%s", base64enc(static_cast<long>(chantime)), channel, user->nick.c_str());
}
/* unsqline
** parv[0] = sender
** parv[1] = nickmask
*/
- void SendSQLineDel(const char *user)
+ void SendSQLineDel(const std::string &user)
{
- if (!user) return;
- send_cmd(NULL, "d %s", user);
+ if (user.empty())
+ return;
+ send_cmd(NULL, "d %s", user.c_str());
}