summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2007-10-25this should fix any of the crashes w00t outlined where User::MyClass == NULL.brain
The simplest fix seems to be that if the user has no class, skip all the code that uses the class values. This makes sense because the only situation where User::MyClass == NULL is when they arent authorised to connect and are being quit so checking flood levels and max sendq etc are irrelevent. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8358 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Implement <connect:limit> - limits how many clients can sit inside a ↵w00t
<connect> tag. Brain, we have a problem here in that if we User::QuitUser() a user with a NULL MyClass member (connect class), then things break (like sendq et al). What should we do with this, create a generic catchall class or something just in case? (to replicate, set up a single connect class with a low limit, and connect too many clients. Crash is the result) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8357 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Remove that goto, capt'nw00t
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8356 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Disable all connect classes, reenable them as we find them in the config. ↵w00t
This stops users using a connect class removed from the conf (or will in a second) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8355 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Finish reference counting connect class stuff. Now rehash removes unused ↵w00t
classes (refcount == 0), and re-reads any new shit (or ones that just got removed) from the config. Possibly todo in the future: make /rehash update classes that exist in memory, make /rehash mark classes removed from conf (but still exist as refcount > 0) as inactive. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8354 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Remove variadic macros from sqlv2 api, removing the warnings that come with ↵brain
it and increasing compatibility git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8353 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Last of the -pedantic fixes. Seems we were all good with -pedantic from the ↵brain
start :) Just seemed that -Wall -Wextra enables moron warnings. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8352 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Tidyupsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8351 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Pedantic safetybrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8350 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Pedantic cleanbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8349 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24-pedantic good, -Wextra bad. read g++ manpage :)brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8348 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24/usr/local/include/openssl/pqueue.h:73: error: ISO C++ does not support ↵brain
`long long' /usr/local/include/openssl/pqueue.h:80: error: ISO C++ does not support `long long' /usr/local/include/openssl/pqueue.h:89: error: ISO C++ does not support `long long' ^^ openssl broken too, set $NoPedantic git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8347 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Some constructors dont initialize the refcount, namely, the one thats ↵brain
usually called :P git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8346 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Whoops forgot thisbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8345 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Obnoxious -pedantic warningsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8344 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Try this w00t, compiles, test running nowbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8343 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Start of refcount-based rehash stuff for <connect> tags, this is broken and ↵w00t
rather ugly right now.. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8342 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-24Theres no need to check the address of a stack declared array for NULL, ↵brain
thanks darix git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8340 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Move some stuff from using userrec cached stuff to using stuff in the ↵w00t
connect classes git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8339 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Fix a bug before I even started this.. don't let User::SetClass() decrease ↵w00t
the reference count if we cannot find the new class to plop them into, that will nark things up nicely.. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8338 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Some more class stuff, blah. Now possible to move a user to a different ↵w00t
class via User::SetClass(), which cmd_oper uses. GetClass() is now just a wrapper around User::MyClass. User::CheckClass() does not support any parameters anymore, nor does User::GetClass().. I think I have this all right ;p git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8337 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Some initial work towards tying <connect> classes to user accounts. This ↵w00t
will (in the longer term) allow for things like limits on how many users can fit in a <connect> for 1.2 git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8336 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Make clean should clean the socketengine objectsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8335 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Windows socket engine tweaksbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8334 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Windows socket engine tweaksbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8333 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Move socketengines into their own dir. This was all w00t's idea, but i told ↵brain
him no because i didnt think it would work. Now ive done it myself :P ner ner ne ner ner :) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8332 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23-Wall is still required, toobrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8331 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23-W -> -Wextrabrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8330 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23This now works properly with $NoPedantic macro.brain
Question: where did all the 'unused parameter' warnings vanish to??? git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8329 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Roll back to 8323, the -pedantic switch thing totally breaks building the ↵brain
way i implemented it here :p git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8328 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Needs a bit more againbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8327 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23And fix it.brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8326 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Add $NoPedantic build macro, for m_mysql because mysql AB dont know how to ↵brain
code :p git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8325 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Visual studio doesnt like throw definitions like thisbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8324 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23All of insp now builds with -pedantic (theres some warnings to squash in ↵brain
modules, and in spanningtree, but its all 'unused parameter'). I suggest we actually go through and satisfy these unused parameter errors for two reasons: (1) it acts as a strong compiler hint leading to better optimization (2) it will give us a good clue of what parameters are NEVER used and should therefore be removed from use (like i just did with AddMode) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8323 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Morebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8322 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23More AddModes fixesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8321 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Some AddMode fixesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8320 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23All the core is now pedantic safe!brain
NOTE: I changed ModeHandler removing a redundant param. Devs, if you find stuff that doesnt compile, change AddMode(handler, 'l') to AddMode(handler); and it will :p git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8319 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23More pedantic safetybrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8318 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Pedantic safebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8317 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23pedantic safebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8316 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Pedantic safebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8315 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Pedantic safebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8314 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23-pedantic tidyups, lets see if it finds anything worthy of a fixbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8313 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Auto generate the install list, no more need to insert it into the ↵brain
.makefile.inc for it to be part of make install git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8312 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-23Oops: Fix one version of overrided match() always being case sensitive..w00t
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8310 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-22Make this a little more bulletproofbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8309 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-22Conditionals in the buildsystem language allowing for checking of configure ↵brain
flags: /* $If: USE_KQUEUE */ /* $ExtraSources: socketengine_kqueue.cpp */ /* $ExtraObjects: socketengine_kqueue.o */ /* $EndIf */ This is used exactly where the example dictates: to pick a socket engine from the socketengine.cpp. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8308 e03df62e-2008-0410-955e-edbf42e46eb7
2007-10-22Remove the need for a bunch of the hard coded arrays/hashes by scanning the ↵brain
src/ dir for tag comments, like in modules git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8307 e03df62e-2008-0410-955e-edbf42e46eb7