brain
f87b555a87
Removed all that lastcreate and wantclose craq from dns.cpp (WHAT THE FUCK WERE THE FIREDNS GUYS SMOKING)
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4454 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 21:46:00 +00:00
brain
9221bcb5a9
Stability fix
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4453 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 20:17:26 +00:00
brain
69ae63ecd2
Change stats recv/send to double, so they can hold truly massive numbers of transferred bytes (they would overflow after about 6 weeks on a busy net otherwise)
...
Fix some warnings
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4450 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 15:03:26 +00:00
brain
592c13592a
Increase size to unsigned long
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4448 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 14:54:18 +00:00
brain
a47ea856ed
Completely remove need for memset.
...
When we uniq_id++, we can wrap to 0 theoretically after 4 billion output messages, HOWEVER, when we do, 0 will be a valid comparison within the array :p
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4447 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 14:52:39 +00:00
brain
40b67389a9
Add #include <sys/select.h> to select engine, we probably need it
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4443 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 13:29:06 +00:00
brain
4f5ef4c1ae
Fix MOTD
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4442 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 13:12:03 +00:00
brain
e5328261b0
Whoops, forgot SocketEngine::SocketEngine() gets called recursively from *Engine::*Engine() (where * is the type being built)
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4441 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 12:58:57 +00:00
brain
3a6885d6a1
* Seperate out socket engines into derived classes of SocketEngine.
...
* Add a classfactory SocketEngineFactory to create a new socketengine of the configured type
* Implement configure hax to compile only the required socketengine and the base class
* Eliminates ugly defines, and is more in line with C++ ways
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4439 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 12:51:21 +00:00
brain
e8c920ce01
Change size of already_sent from char to int to work with uniq_id value
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4438 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 11:13:15 +00:00
brain
b137f2564c
Speed up writecommon, writecommon_noformat, writechannel, etc (by quite a bit) - eliminate 99.99999999999% of the memsets
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4437 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 11:00:55 +00:00
brain
deccd86592
Special checking for muppet providers that make their reverse resolution resolve back to the same reverse resolution.
...
*WHY* DO PEOPLE IN CONTROL OF THE RDNS RECORDS EVEN *ALLOW* SUCH LUNACY?!
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4436 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 10:47:46 +00:00
brain
8f1f87ce10
Fix motd with new buffering
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4434 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-19 09:16:45 +00:00
brain
983f18f834
Tried to implement sprintf that returns std::string of any size, realized it would scale like unreal scales to ircnet (e.g. it wouldnt!) so took it back out.
...
Moved chop() functionality into userrec::AddWriteBuf and make it nicer (no strlen)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4433 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-18 21:43:37 +00:00
brain
69f280701b
Tweaks for nonblocking dns
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4432 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 21:28:09 +00:00
brain
93a796af16
Improved connect time by not referencing the hash for each user value, store a temp pointer
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4431 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 21:23:27 +00:00
brain
51fb508494
Ignore empty lines, don't try and process them as commands
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4430 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 20:13:40 +00:00
brain
6e25565827
Only attempt forward lookup if the user still exists
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4428 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 20:01:16 +00:00
brain
09dbf0f948
Remove some casts
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4427 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 19:58:25 +00:00
brain
d8fbbeafdf
Craq removal service, at your service
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4426 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 19:54:17 +00:00
brain
1e232ef237
i'm doing this in increments, because if i try and change too much at once, it breaks
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4425 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 19:45:24 +00:00
brain
dcad2fe327
Fixing sendq crask
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4424 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 19:43:38 +00:00
om
c17d4bc92c
Update to new API - I think this is right, compiles...
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4422 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 19:14:31 +00:00
brain
2dfa145d99
Fixed it myself so i can carry on coding1
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4421 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 17:49:43 +00:00
w00t
fe6158e237
More WHO
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4420 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 17:27:49 +00:00
w00t
3a7c9d1180
WHO refactoring. In progress currently.
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4419 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 17:03:35 +00:00
brain
f8956e4b45
*Changed user input/output buffering to incur less copies
...
*Fix warnings in command_parse
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4418 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 15:45:13 +00:00
w00t
b07953b0e7
Change to a DIFFERENT HOOK for added goodness.
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4417 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 15:44:00 +00:00
brain
fae424910d
Document loopcall (its still complicated in concept, but now easier to read and possibly easier to understand)
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4413 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 15:21:34 +00:00
brain
085cd4278f
Created new class irc::commasepstream.
...
Will read comma seperated lists and works identically to irc::tokenstream
It's re-entrant so we can run two of them together for JOIN
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4412 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 15:08:59 +00:00
brain
863d8a3d08
Adjustment
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4410 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 14:30:50 +00:00
brain
d787576389
Fix socket leak properly this time
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4405 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 13:52:10 +00:00
brain
5d18f26b6b
Fix case sensitive commands issue due to new std::string based parser, improve the craq disabled commands check that was potentially O(n) where n is the number of disabled commands (erk)
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4404 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 13:02:38 +00:00
brain
0757a4a495
mass tidyup, change A LOT of stuff to const char** which was char** (such as parameters to commands in handlers)
...
which makes the new lineparser work neater with no casts. This also removes tons of casts from other locations
(all in all, ive added 2 casts and removed almost a hundred)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4403 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 12:18:29 +00:00
brain
80d1296c31
MAJOR tidy of line parser, some parts rewritten and major chunks removed
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4402 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 08:38:33 +00:00
om
8ce25663a9
Fixes/codes of the query queue, various prototypes and stuff...mostly commited so I can do other stuff without typing the paths out manually
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4401 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 07:24:17 +00:00
om
c195e03e61
const the std::string reference in tokenstream's constructor
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4400 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 07:23:03 +00:00
brain
b3bab5a002
Disable test suite
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4399 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 02:16:10 +00:00
brain
654482dc4f
Improved this a lot
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4398 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 02:15:45 +00:00
brain
ef10f984fa
This should be faster, we read it like a stream now with GetToken until GetToken returns "".
...
The optimizations done by gcc means theres only one std::string constructor call per token, which is mmm yum.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4397 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 02:09:58 +00:00
brain
6ab0b94dce
irc::tokenstream is a token parser which using std::string and std::vector builds a list of tokens using irc parsing rules.
...
e.g.:
:arse PRIVMSG #chan :foo bar baz
becomes
a[0] = ":arse", a[1] = "PRIVMSG", a[2] = "#chan", a[3] = "foo bar baz".
*** SOMEONE *** needs to optimize this or at least verify its neatness (without making it total craq and unreadable). Feel free to mess with my code.
Any optimizations you make, run them against the COMMENTED OUT TEST SUITE at the top of main() in src/inspircd.cpp and ensure ALL output is the same
with no crashes. (note: if you comment out and build with the test suite, all inspircd will do is output test data and exit!)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4396 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16 01:40:58 +00:00
brain
5454b47bd5
Removed GCC2 checks as we havent supported gcc2 for years
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4394 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-15 17:35:31 +00:00
brain
a551684ab0
Don't allow SAQUIT, SANICK, SAPART and SAJOIN on ulined clients :)
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4390 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-14 16:08:48 +00:00
brain
b06846c089
Tidyup
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4389 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-14 15:28:16 +00:00
brain
bb2daddfaa
Changed to different way of clearing users on netsplit (uses less ram and should be less bug prone)
...
WE NEED TESTERS FOR THIS. MAKE TEST NETWORKS FULL OF 1_0_STABLE SVN SERVERS AND FILL THEM WITH BOTS/PSEUDOS THEN CAUSE NETSPLITS!
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4388 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-14 15:25:25 +00:00
brain
d4ca01f12f
Add <options:nouserdns> - defaults to off. if set to on, no user dns lookups are performed, saving resources
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4386 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-14 13:02:40 +00:00
brain
174169ac35
Rollback dns change
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4384 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-14 12:14:42 +00:00
brain
ccb1837a14
Fix dns socket leak found in stable
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4383 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-14 11:43:17 +00:00
brain
9e754af283
Final test.
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4375 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-12 19:36:39 +00:00
brain
90c8377bc8
Test
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4374 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-12 19:34:27 +00:00