* | Inspire Internet Relay Chat Daemon |
* +------------------------------------+
*
- * InspIRCd: (C) 2002-2008 InspIRCd Development Team
+ * InspIRCd: (C) 2002-2009 InspIRCd Development Team
* See: http://www.inspircd.org/wiki/index.php/Credits
*
* This program is free but copyrighted software; see
*/
#include "inspircd.h"
-#include "wildcard.h"
/* $ModDesc: Provides the TITLE command which allows setting of CUSTOM WHOIS TITLE line */
std::string xhost;
while (hl >> xhost)
{
- if (match(host, xhost) || match(ip,xhost, true))
+ if (InspIRCd::Match(host, xhost, ascii_case_insensitive_map) || InspIRCd::MatchCIDR(ip, xhost, ascii_case_insensitive_map))
{
return true;
}
if (!strcmp(name.c_str(),parameters[0].c_str()) && !ServerInstance->PassCompare(user, pass.c_str(), parameters[1].c_str(), hash.c_str()) && OneOfMatches(TheHost,TheIP,host.c_str()) && !title.empty())
{
std::string* text;
- user->GetExt("ctitle", text);
-
- if (text)
+ if (user->GetExt("ctitle", text))
{
user->Shrink("ctitle");
delete text;
{
/* Insert our numeric before 312 */
std::string* ctitle;
- dest->GetExt("ctitle", ctitle);
- if (ctitle)
+ if (dest->GetExt("ctitle", ctitle))
{
ServerInstance->SendWhoisLine(user, dest, 320, "%s %s :%s",user->nick.c_str(), dest->nick.c_str(), ctitle->c_str());
}
{
// check if this user has an ctitle field to send
std::string* ctitle;
- user->GetExt("ctitle", ctitle);
- if (ctitle)
+ if (user->GetExt("ctitle", ctitle))
{
// call this function in the linking module, let it format the data how it
// sees fit, and send it on its way. We dont need or want to know how.
virtual void OnUserQuit(User* user, const std::string &message, const std::string &oper_message)
{
std::string* ctitle;
- user->GetExt("ctitle", ctitle);
- if (ctitle)
+ if (user->GetExt("ctitle", ctitle))
{
user->Shrink("ctitle");
delete ctitle;
{
User* user = (User*)item;
std::string* ctitle;
- user->GetExt("ctitle", ctitle);
- if (ctitle)
+ if (user->GetExt("ctitle", ctitle))
{
user->Shrink("ctitle");
delete ctitle;
virtual Version GetVersion()
{
- return Version(1, 2, 0, 0, VF_COMMON | VF_VENDOR, API_VERSION);
+ return Version("$Id$", VF_COMMON | VF_VENDOR, API_VERSION);
}
};