diff options
| author | 2011-05-23 21:52:52 -0400 | |
|---|---|---|
| committer | 2011-05-23 21:52:52 -0400 | |
| commit | cbbd56b8290f6569a815cf05ca7bd79279fa1b94 (patch) | |
| tree | 52ee08e82faf1abe863b1635ac7acafc2e1ffc49 /include | |
| parent | Change InspIRCd::Run() to return void (diff) | |
Fix recursion of QuitUser in SendQ quits
Diffstat (limited to 'include')
| -rw-r--r-- | include/cull_list.h | 2 | ||||
| -rw-r--r-- | include/users.h | 6 |
2 files changed, 8 insertions, 0 deletions
diff --git a/include/cull_list.h b/include/cull_list.h index 960874bd6..db1ac28db 100644 --- a/include/cull_list.h +++ b/include/cull_list.h @@ -22,11 +22,13 @@ class CoreExport CullList { std::vector<classbase*> list; + std::vector<LocalUser*> SQlist; public: /** Adds an item to the cull list */ void AddItem(classbase* item) { list.push_back(item); } + void AddSQItem(LocalUser* item) { SQlist.push_back(item); } /** Applies the cull list (deletes the contents) */ diff --git a/include/users.h b/include/users.h index 215b58a1d..f8bf5d009 100644 --- a/include/users.h +++ b/include/users.h @@ -278,6 +278,12 @@ class CoreExport User : public Extensible */ unsigned int quitting:1; + /** Recursion fix: user is out of SendQ and will be quit as soon as possible. + * This can't be handled normally because QuitUser itself calls Write on other + * users, which could trigger their SendQ to overrun. + */ + unsigned int quitting_sendq:1; + /** This is true if the user matched an exception (E:Line). It is used to save time on ban checks. */ unsigned int exempt:1; |
