summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-08-29 19:45:03 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-08-29 19:45:03 +0000
commit645d9e7838a33e01c58d8a846f6b2687a8e8757d (patch)
tree5ddcb41881bb9182480224b64bd6849eb91fe9d7 /src
parentd10e9cce473fd0ef1e56b850e581b331e1d7494c (diff)
IMPORTANT: UID command now takes TEN parameters in 1.2. We never had a signon time seperate from the TS in the UID command (or 1.1's NICK command) because in 1.1 this timestamp never updated
and was therefore useful for both values. This is no longer the case and we must pass both seperately git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7988 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/modules/m_spanningtree/treesocket1.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/modules/m_spanningtree/treesocket1.cpp b/src/modules/m_spanningtree/treesocket1.cpp
index d89d454e2..d8576c2e4 100644
--- a/src/modules/m_spanningtree/treesocket1.cpp
+++ b/src/modules/m_spanningtree/treesocket1.cpp
@@ -1005,18 +1005,20 @@ bool TreeSocket::ParseUID(const std::string &source, std::deque<std::string> &pa
/** Do we have enough parameters:
* UID uuid age nick host dhost ident +modestr ip.string :gecos
*/
- if (params.size() != 9)
+ if (params.size() != 10)
{
- this->WriteLine(std::string(":")+this->Instance->Config->GetSID()+" KILL "+params[0]+" :Invalid client introduction ("+params[0]+"?)");
+ this->WriteLine(std::string(":")+this->Instance->Config->GetSID()+" KILL "+params[0]+" :Invalid client introduction ("+params[0]+" with only "+
+ ConvToStr(params.size())+" of 10 parameters?)");
return true;
}
time_t age = ConvToInt(params[1]);
+ time_t signon = ConvToInt(params[8]);
const char* tempnick = params[2].c_str();
std::string empty;
/* XXX probably validate UID length too -- w00t */
- cmd_validation valid[] = { {"Nickname", 2, NICKMAX}, {"Hostname", 3, 64}, {"Displayed hostname", 4, 64}, {"Ident", 5, IDENTMAX}, {"GECOS", 7, MAXGECOS}, {"", 0, 0} };
+ cmd_validation valid[] = { {"Nickname", 2, NICKMAX}, {"Hostname", 3, 64}, {"Displayed hostname", 4, 64}, {"Ident", 5, IDENTMAX}, {"GECOS", 9, MAXGECOS}, {"", 0, 0} };
TreeServer* remoteserver = Utils->FindServer(source);
@@ -1084,7 +1086,7 @@ bool TreeSocket::ParseUID(const std::string &source, std::deque<std::string> &pa
strlcpy(_new->ident, params[5].c_str(),IDENTMAX);
strlcpy(_new->fullname, params[8].c_str(),MAXGECOS);
_new->registered = REG_ALL;
- _new->signon = age;
+ _new->signon = signon;
_new->age = age;
/* we need to remove the + from the modestring, so we can do our stuff */