X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fxline.cpp;h=0878ec286e5c412bde4d87bd66d4d74ab5b8c0d8;hb=5db3290d939509015167b7fdfba5073285051560;hp=5d5a95516b27ec8e3a998c3d9d6b3610163f437e;hpb=4b856bda135a08e800b96c970a10b0b6a34d433a;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/xline.cpp b/src/xline.cpp index 5d5a95516..0878ec286 100644 --- a/src/xline.cpp +++ b/src/xline.cpp @@ -116,6 +116,22 @@ XLineLookup* XLineManager::GetAll(const std::string &type) return &(n->second); } +void XLineManager::DelAll(const std::string &type) +{ + ContainerIter n = lookup_lines.find(type); + + if (n == lookup_lines.end()) + return; + + LookupIter x; + + /* Delete all of a given type (this should probably use DelLine, but oh well) */ + while ((x = n->second.begin()) != n->second.end()) + { + ExpireLine(n, x); + } +} + std::vector XLineManager::GetAllTypes() { std::vector items;