summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Powell <petpow@saberuk.com>2019-05-17 09:23:46 +0100
committerPeter Powell <petpow@saberuk.com>2019-05-17 09:23:46 +0100
commitf9a258fa768362279cb5365856fe3f4dce5d6245 (patch)
tree195c9597774e6f158e443d3a4eca5ab1c2a27eed
parent0ab7720ea4b53996a4bb6b8e47e8aae9304861a1 (diff)
Only skip applying more X-lines to a user if they have been killed.
This fixes an issue with the previous commit where if a user had a non-killing X-line applied to them (e.g. Q-line) they would not have any further X-lines applied to them. Thanks to @linuxdaemon for pointing this out.
-rw-r--r--src/xline.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/xline.cpp b/src/xline.cpp
index f9d94e447..accffb8d0 100644
--- a/src/xline.cpp
+++ b/src/xline.cpp
@@ -460,7 +460,11 @@ void XLineManager::ApplyLines()
if (x->Matches(u))
{
x->Apply(u);
- break;
+
+ // If applying the X-line has killed the user then don't
+ // apply any more lines to them.
+ if (u->quitting)
+ break;
}
}
}