diff options
| author | 2007-08-28 13:48:28 +0000 | |
|---|---|---|
| committer | 2007-08-28 13:48:28 +0000 | |
| commit | 19157777c5f977fddbcfdc8cdad78e12bf0d6bbb (patch) | |
| tree | e3e860f214483978dbd01fa8526b3e1fdf4db053 /src/modules/m_spanningtree/treesocket1.cpp | |
| parent | Remove an utterly insane comment .. based on changed by based on originally b... (diff) | |
Remove the last uses of localised fake clients. This removes a lot of allocations (and uses of UIDs), and cleans things up a bit
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7943 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_spanningtree/treesocket1.cpp')
| -rw-r--r-- | src/modules/m_spanningtree/treesocket1.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/modules/m_spanningtree/treesocket1.cpp b/src/modules/m_spanningtree/treesocket1.cpp index 1a7531074..872b1d72f 100644 --- a/src/modules/m_spanningtree/treesocket1.cpp +++ b/src/modules/m_spanningtree/treesocket1.cpp @@ -640,9 +640,8 @@ bool TreeSocket::ForceMode(const std::string &source, std::deque<std::string> &p } else { - /* FMODE from a server, create a fake user to receive mode feedback */ - who = new userrec(this->Instance); - who->SetFd(FD_MAGIC_NUMBER); + /* FMODE from a server, use a fake user to receive mode feedback */ + who = this->Instance->FakeClient; smode = true; /* Setting this flag tells us we should free the userrec later */ sourceserv = source; /* Set sourceserv to the actual source string */ } @@ -714,10 +713,6 @@ bool TreeSocket::ForceMode(const std::string &source, std::deque<std::string> &p } /* If the TS is greater than ours, we drop the mode and dont pass it anywhere. */ - - if (smode) - DELETE(who); - return true; } @@ -896,8 +891,6 @@ bool TreeSocket::ForceJoin(const std::string &source, std::deque<std::string> &p { std::deque<std::string> stackresult; const char* mode_junk[MAXMODES+2]; - userrec* n = new userrec(Instance); - n->SetFd(FD_MAGIC_NUMBER); mode_junk[0] = channel.c_str(); while (modestack.GetStackedLine(stackresult)) @@ -906,10 +899,8 @@ bool TreeSocket::ForceJoin(const std::string &source, std::deque<std::string> &p { mode_junk[j+1] = stackresult[j].c_str(); } - Instance->SendMode(mode_junk, stackresult.size() + 1, n); + Instance->SendMode(mode_junk, stackresult.size() + 1, Instance->FakeClient); } - - delete n; } return true; |
