]> arthur.barton.de Git - ngircd-alex.git/commit
Connection counter: count outgoing connections as well.
authorAlexander Barton <alex@barton.de>
Wed, 12 Nov 2008 00:23:33 +0000 (01:23 +0100)
committerAlexander Barton <alex@barton.de>
Wed, 12 Nov 2008 00:26:04 +0000 (01:26 +0100)
commit9f067a059d9f64c68a73a2f7fbf5308ee342fe2a
tree68fafcb2027b3f41ac85bdbabf2f7b305f9d1411
parent5a91d621009d6a0f3b8e5ff054aa6ae7e3195191
Connection counter: count outgoing connections as well.

This patch lets ngIRCd count outgoing connections as well as incoming
connections (up to now only outgoing connections have been counted). This
change is required because the Conn_Close() function doesn't know whether
it closes an outgoing connection or not and therefore would decrement the
counter below zero when an outgoing connection existed -- which would
trigger an assert() call ...

Please note that this patch changes the (so far undocumented but now fixed)
behaviour of the "MaxConnections" configuration option to account the sum
of the in- and outbound connections!
doc/sample-ngircd.conf
man/ngircd.conf.5.tmpl
src/ngircd/conn.c