X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Finspircd.h;h=ee1a5120a4b1461e67c6b7e8100484a149906619;hb=4840d5e77572f42b710501912d59b5dbb6d2c2af;hp=4dc90c8e81f8e143dd531c32af9aca17936679c2;hpb=03e0fb206d3f5709868f03bc7a401cb666c38ffb;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/inspircd.h b/include/inspircd.h index 4dc90c8e8..ee1a5120a 100644 --- a/include/inspircd.h +++ b/include/inspircd.h @@ -77,7 +77,7 @@ template inline std::string ConvNumeric(const T &in) ++out; quotient /= 10; } - if ( in < 0) + if (in < 0) *out++ = '-'; *out = 0; std::reverse(res,out); @@ -98,13 +98,6 @@ inline std::string ConvToStr(const long in) return ConvNumeric(in); } -/** Template function to convert any input type to std::string - */ -inline std::string ConvToStr(const unsigned long in) -{ - return ConvNumeric(in); -} - /** Template function to convert any input type to std::string */ inline std::string ConvToStr(const char* in) @@ -269,7 +262,7 @@ class CoreExport InspIRCd : public classbase */ bool DaemonSeed(); - /** Iterate the list of InspSocket objects, removing ones which have timed out + /** Iterate the list of BufferedSocket objects, removing ones which have timed out * @param TIME the current time */ void DoSocketTimeouts(time_t TIME); @@ -279,9 +272,8 @@ class CoreExport InspIRCd : public classbase void InitialiseUID(); /** Perform background user events such as PING checks - * @param TIME the current time */ - void DoBackgroundUserStuff(time_t TIME); + void DoBackgroundUserStuff(); /** Returns true when all modules have done pre-registration checks on a user * @param user The user to verify @@ -340,10 +332,10 @@ class CoreExport InspIRCd : public classbase FindDescriptorHandler HandleFindDescriptor; FloodQuitUserHandler HandleFloodQuitUser; - /** InspSocket classes pending deletion after being closed. + /** BufferedSocket classes pending deletion after being closed. * We don't delete these immediately as this may cause a segmentation fault. */ - std::map SocketCull; + std::map SocketCull; /** Globally accessible fake user record. This is used to force mode changes etc across s2s, etc.. bit ugly, but.. better than how this was done in 1.1 * Reason for it: @@ -463,10 +455,6 @@ class CoreExport InspIRCd : public classbase */ XLineManager* XLines; - /** The time we next call our ping timeout and reg timeout checks - */ - time_t next_call; - /** Set to the current signal recieved */ int s_signal; @@ -686,11 +674,6 @@ class CoreExport InspIRCd : public classbase */ int RegisteredUserCount(); - /** Return a count of invisible (umode +i) users only - * @return The number of invisible users - */ - int InvisibleUserCount(); - /** Return a count of opered (umode +o) users only * @return The number of opers */ @@ -737,10 +720,9 @@ class CoreExport InspIRCd : public classbase /** Add a new mode to this server's mode parser * @param mh The modehandler to add - * @param modechar The mode character this modehandler handles * @return True if the mode handler was added */ - bool AddMode(ModeHandler* mh, const unsigned char modechar); + bool AddMode(ModeHandler* mh); /** Add a new mode watcher to this server's mode parser * @param mw The modewatcher to add @@ -813,76 +795,6 @@ class CoreExport InspIRCd : public classbase */ bool IsValidModuleCommand(const std::string &commandname, int pcnt, User* user); - /** Add a gline and apply it - * @param duration How long the line should last - * @param source Who set the line - * @param reason The reason for the line - * @param hostmask The hostmask to set the line against - */ - void AddGLine(long duration, const std::string &source, const std::string &reason, const std::string &hostmask); - - /** Add a qline and apply it - * @param duration How long the line should last - * @param source Who set the line - * @param reason The reason for the line - * @param nickname The nickmask to set the line against - */ - void AddQLine(long duration, const std::string &source, const std::string &reason, const std::string &nickname); - - /** Add a zline and apply it - * @param duration How long the line should last - * @param source Who set the line - * @param reason The reason for the line - * @param ipaddr The ip-mask to set the line against - */ - void AddZLine(long duration, const std::string &source, const std::string &reason, const std::string &ipaddr); - - /** Add a kline and apply it - * @param duration How long the line should last - * @param source Who set the line - * @param reason The reason for the line - * @param hostmask The hostmask to set the line against - */ - void AddKLine(long duration, const std::string &source, const std::string &reason, const std::string &hostmask); - - /** Add an eline - * @param duration How long the line should last - * @param source Who set the line - * @param reason The reason for the line - * @param hostmask The hostmask to set the line against - */ - void AddELine(long duration, const std::string &source, const std::string &reason, const std::string &hostmask); - - /** Delete a gline - * @param hostmask The gline to delete - * @return True if the item was removed - */ - bool DelGLine(const std::string &hostmask); - - /** Delete a qline - * @param nickname The qline to delete - * @return True if the item was removed - */ - bool DelQLine(const std::string &nickname); - - /** Delete a zline - * @param ipaddr The zline to delete - * @return True if the item was removed - */ - bool DelZLine(const std::string &ipaddr); - - /** Delete a kline - * @param hostmask The kline to delete - * @return True if the item was removed - */ - bool DelKLine(const std::string &hostmask); - - /** Delete an eline - * @param hostmask The kline to delete - * @return True if the item was removed - */ - bool DelELine(const std::string &hostmask); - /** Return true if the given parameter is a valid nick!user\@host mask * @param mask A nick!user\@host masak to match against * @return True i the mask is valid @@ -1057,10 +969,10 @@ class CoreExport InspIRCd : public classbase */ int Run(); - /** Force all InspSockets to be removed which are due to + /** Force all BufferedSockets to be removed which are due to * be culled. */ - void InspSocketCull(); + void BufferedSocketCull(); char* GetReadBuffer() {