summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree/nick.cpp
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2014-07-26 16:00:24 +0200
committerAttila Molnar <attilamolnar@hush.com>2014-07-26 16:00:24 +0200
commit4464121eb232a3ec6049802256012714fe786506 (patch)
tree480dda7a185d0331bc9da9a07af130f7bc274981 /src/modules/m_spanningtree/nick.cpp
parentdf4afba6c23c939af1013582c94138832017af4e (diff)
m_spanningtree Return a bool from DoCollision()
The return value is true if the remote user or both have to change, false if only we have to change
Diffstat (limited to 'src/modules/m_spanningtree/nick.cpp')
-rw-r--r--src/modules/m_spanningtree/nick.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/nick.cpp b/src/modules/m_spanningtree/nick.cpp
index cdec280e1..9f0d78a65 100644
--- a/src/modules/m_spanningtree/nick.cpp
+++ b/src/modules/m_spanningtree/nick.cpp
@@ -47,8 +47,8 @@ CmdResult CommandNick::HandleRemote(RemoteUser* user, std::vector<std::string>&
{
// 'x' is the already existing user using the same nick as params[0]
// 'user' is the user trying to change nick to the in use nick
- int collideret = Utils->DoCollision(x, TreeServer::Get(user), newts, user->ident, user->GetIPString(), user->uuid);
- if (collideret != 1)
+ bool they_change = Utils->DoCollision(x, TreeServer::Get(user), newts, user->ident, user->GetIPString(), user->uuid);
+ if (they_change)
{
// Remote client lost, or both lost, rewrite this nick change as a change to uuid before
// calling ChangeNick() and forwarding the message