aboutsummaryrefslogtreecommitdiff
path: root/src/helperfuncs.cpp
Commit message (Expand)AuthorAgeFilesLines
...
* Introduce Server class•••- Replaces std::string server in User - Replaces InspIRCd::ULine() and SilentULine() Gravatar Attila Molnar2014-01-051-17/+0
* Clean up CoreException•••- Remove default constructor - Replace virtual functions returning C strings with functions returning const std::string refs Gravatar Attila Molnar2013-12-181-2/+2
* Fix issues discovered by Coverity•••- Fix resource leak in InspIRCd::Format() - Explicitly set NewServices to NULL before the object it points to goes out of scope Gravatar Daniel Vassdal2013-12-181-0/+2
* Use WriteNumeric() everywhere we send numerics and include the user's nick au...Gravatar Adam2013-11-121-1/+1
* Move prefix mode specific fields and getters into PrefixMode•••Add ModeHandler::IsPrefixMode() Gravatar attilamolnar2013-09-111-1/+1
* Merge insp20Gravatar attilamolnar2013-08-301-1/+20
|\
| * Fix crash caused by passing a large integer to ctime()•••In addition to verifying the return value of localtime(), correct tm_year if it is out of bounds Reported by @JDowny Gravatar attilamolnar2013-08-271-1/+20
* | Change the syntax of FOREACH macros to be less dumb.Gravatar Adam2013-08-041-1/+1
* | Remove $Core and $Mod* comments apart from $ModDep.Gravatar Peter Powell2013-07-041-2/+0
* | Move a few trivial functions into headersGravatar attilamolnar2013-06-021-6/+0
* | Some systems with whacky va_list implementations do undefined stuff when vsnp...Gravatar Adam2013-05-231-3/+15
* | Merge pull request #545 from SaberUK/master+logging-cleanup•••Clean up the logging system (part 1 of 2).Gravatar Attila Molnar2013-05-211-23/+1
|\ \
| * | Fix spacing in calls to LogManager::Log.Gravatar Peter Powell2013-05-191-1/+1
| * | Purge a ton of code related to non <log> related logging.•••- InspIRCd::OpenLog - ./inspircd --logfile [file] This is no longer needed now we have (since 1.2) custom logging. Gravatar Peter Powell2013-05-191-22/+0
* | | Fixup last commitGravatar Adam2013-05-201-1/+1
* | | Replaced vsnprintf with VAFORMAT pretty much everywhere.Gravatar Daniel Vassdal2013-05-181-7/+3
* | | Added macro to allow simpler logic in functions with the need to vsnprintfGravatar Daniel Vassdal2013-05-181-5/+8
|/ /
* | Remove the size argument from IsChannel and IsNick.•••There was only one case (which was probably an error) where these methods were not set to their ServerLimits value. Gravatar Peter Powell2013-05-181-4/+4
* | Added a function to replace all the ugly sprintf-ing everywhereGravatar Daniel Vassdal2013-05-161-0/+13
* | Add method for writing server notices.•••This allows us to send a server notice to a user without worrying about whether they are registered or not. If a user receives a server notice and they are not registered then the nickname field will contain an asterisk instead of their nick name. Gravatar Peter Powell2013-05-141-2/+2
* | Remove const char* versions of InspIRCd::FindNick()/FindNickOnly()/FindUUID()...Gravatar attilamolnar2013-04-131-39/+0
* | Add LOG_ prefix to the log level enum values.Gravatar Peter Powell2013-04-121-2/+2
* | Convert ISUPPORT to use a map instead of a string.Gravatar Peter Powell2013-04-111-20/+0
* | Convert InspIRCd::Duration() to be staticGravatar attilamolnar2013-04-031-1/+1
* | Change IsNickHandler()/IsIdentHandler()/IsChannelHandler() to use C++ strings...Gravatar attilamolnar2013-04-011-27/+14
* | Convert IsSID() to a static member function, modules shouldn't override itGravatar attilamolnar2013-04-011-1/+1
|/
* Remove ServerLimits::Finalise(), it's completely wrong•••Truncate <limits:identmax>+1 long idents in User::ChangeIdent() Gravatar attilamolnar2012-12-091-2/+2
* Add a typedef for LocalUserListGravatar attilamolnar2012-11-291-1/+1
* Have FindUUID(const char*) call FindUUID(const std::string&), not the other w...Gravatar attilamolnar2012-11-281-5/+5
* Move ServerConfig::ProcessColors() into class InspIRCd, as a helper function•••Change signature to accept a file_cache reference so modules can use it easily Gravatar attilamolnar2012-10-291-0/+57
* Fix for #268.•••- Move color stripping code to helperfuncs. - Strip color codes before matching filters. Gravatar Peter Powell2012-10-191-0/+27
* Replace printf(_c) with iostreamGravatar ChrisTX2012-10-141-2/+3
* Windows: In-depth cleanup (see details)•••-Fix x64 builds for Windows. Now all configurations compile. -Remove the non-working rebase stuff. -Remove the Windows fork hack and instead use FreeConsole() to emulate the behavior. This directly allows us to compile with ASLR, which is turned on now. -Remove the old IPC mechanism for the removed GUI. This is not needed anymore as the GUI wasn't ever supported on anything newer than 1.2 -Remove the WIN32/WINDOWS macros. _WIN32 is supported on all x86-based VC++ targets, so that's what we need. -Enable optimizations for release builds. -De-duplicate printf_c(), it was previously copy-pasted into colors.h for configure -Add the VC++ specific bad files in .gitignore -Disable PID writing on Windows. This is only making sense for *nix builds. -Replace the CPU usage retrieval with an algorithm analogous to the *nix behavior. Also supports separated now/total values. (Tested with a dummy busy loop - seems working) -Removed certain unused functions and variables -Remove stdint defines from the windows wrapper -Remove CRT debug alloc. This is a bad idea as it would define a macro to replace free which breaks builds. -Re-evaluated the warnings list, commented it. -Moved inspircd_config/_version to include/ to match *nix -Removed the creation of inspircd_se_config, as it isn't used at all. -Made non-git builds show as "r0" instead of "r" (thanks to @SaberUK for pointing this out) -Fixed up m_spanningtree's project paths. Now all configurations (debug/release x86/x64) have been tested and build properly. -Moved FindDNS out of the wrapper and matched its log behavior with *nix. (It's pointless having it in the wrapper after the recent slimming down) -Replaced random/srandom wrappers with a mechanism that tries to use Windows' Random API first is no SSL module is loaded. -Removed more old junk from support for compilers older than VC++ 2010 (we don't have project files for these, so compiling them would be hard anyways) -Removed the unused ClearConsole() -Removed unused includes from the wrapper. Also, do not include psapi.h here if we don't link psapi.lib. This should be done where appropriate. -Made inet_aton an inline function for increased performance -C4800, performance warning about bool forcing, resolved at all occurrences. -C4701, uninitialized variable 'cached', resolved at all occurrences. -dlerror() was migrated out of the wrapper for more thread safety (no global buffer being shared) and increased performance. -Removed the wrong CRT debug flags. This drains a lot of performance. -Removed the clock_gettime/gettimeofday wrappers -Replaced all TCHAR/ANSI mix-ups of functions with the correct respective function. -Added a block of C4355 for < VS2012 -Update project files for c870714 Gravatar ChrisTX2012-10-121-0/+17
* Replace hardcoded paths with configurable ones•••This patchset aims to ease the packaging of InspIRCd for a system-wide installation scenario. Changes in detail: configure: Add the options --log-path and --data-path m_ssl_gnutls, openssl: Change the hardcoded "conf/" to the existent CONFIG_PATH macro m_xline_db: Make the location of xline.db configurable. It will use --data-path as default value, but this can be changed using the configuration files. Gravatar ChrisTX2012-10-041-1/+1
* Replace copyright headers with headers granting specific authors copyrightGravatar Robby-2012-04-191-8/+19
* Cap masks and bans at 250 characters•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12575 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2010-03-011-0/+3
* Fix compilation warning•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12504 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2010-02-201-1/+1
* Restore <options:exemptchanops> with long names•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12502 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2010-02-201-0/+25
* Add random number generation functions to InspIRCd class.•••Default implementation uses libc random(), which can be better than rand(). If gnutls is loaded, gcrypt will be used to provide random numbers. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12404 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2010-02-091-0/+28
* Sort items in the 005 line•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12351 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2010-02-021-3/+8
* ...because every now and again, i have to do a massive commit.•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12248 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar brain2010-01-111-1/+1
* Move command-line items to CommandLineConf•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11949 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-10-211-24/+7
* Split LocalUser and RemoteUser•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11940 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-10-211-1/+1
* Change to new execution directory structure•••Don't change CWD into bin/ Remove path-resolution hacks from configuration Store pidfile and xline DBs in data, logs in logs. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11866 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-10-131-15/+1
* Fix valgrind issues and crashes on exit•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11794 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-10-021-9/+8
* Remove InspIRCd* parameters and fields•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11763 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-09-261-5/+5
* Create StreamSocket for IO hooking implementation•••Fixes the SSL SendQ bug Removes duplicate code between User and BufferedSocket Simplify SSL module API Simplify EventHandler API (Readable/Writeable moved to SE) Add hook for culled objects to invoke callbacks prior to destructor Replace SocketCull with GlobalCull now that sockets can close themselves Shorten common case of user read/parse/write path: User::Write is now zero-copy up to syscall/SSL invocation User::Read has only two copy/scan passes from read() to ProcessCommand git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11752 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-09-211-8/+4
* ModResult conversion: Change return type of all module functions•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11634 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-09-021-2/+2
* Cast rework: use C++ style static_cast<> instead of C-style casts•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11595 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-09-021-2/+2
* Fixes for config reader•••git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11504 e03df62e-2008-0410-955e-edbf42e46eb7 Gravatar danieldg2009-08-121-10/+0