* | Inspire Internet Relay Chat Daemon |
* +------------------------------------+
*
- * InspIRCd: (C) 2002-2008 InspIRCd Development Team
- * See: http://www.inspircd.org/wiki/index.php/Credits
+ * InspIRCd: (C) 2002-2009 InspIRCd Development Team
+ * See: http://wiki.inspircd.org/Credits
*
* This program is free but copyrighted software; see
* the file COPYING for details.
time_t rawtime = u->signon;
tm *timeinfo;
char b[MAXBUF];
-
+
timeinfo = localtime(&rawtime);
-
+
/* XXX - 'b' could be only 25 chars long and then strlcpy() would terminate it for us too? */
strlcpy(b,asctime(timeinfo),MAXBUF);
b[24] = 0;
user->WriteNumeric(314, "%s %s %s %s * :%s",user->nick.c_str(),parameters[0].c_str(),u->ident,u->dhost,u->gecos);
-
- if (IS_OPER(user))
+
+ if (user->HasPrivPermission("users/auspex"))
user->WriteNumeric(379, "%s %s :was connecting from *@%s", user->nick.c_str(), parameters[0].c_str(), u->host);
-
- if (*ServerInstance->Config->HideWhoisServer && !IS_OPER(user))
+
+ if (*ServerInstance->Config->HideWhoisServer && !user->HasPrivPermission("servers/auspex"))
user->WriteNumeric(312, "%s %s %s :%s",user->nick.c_str(),parameters[0].c_str(), ServerInstance->Config->HideWhoisServer, b);
else
user->WriteNumeric(312, "%s %s %s :%s",user->nick.c_str(),parameters[0].c_str(), u->server, b);
WhoWasGroup::WhoWasGroup(User* user) : host(NULL), dhost(NULL), ident(NULL), server(NULL), gecos(NULL), signon(user->signon)
{
- this->host = strdup(user->host);
+ this->host = strdup(user->host.c_str());
this->dhost = strdup(user->dhost.c_str());
this->ident = strdup(user->ident.c_str());
this->server = user->server;