Committer : entrope
CVSROOT : /cvsroot/undernet-ircu
Module : ircu2.10
Commit time: 2005-05-30 21:11:49 UTC
Modified files:
ircd/s_debug.c ChangeLog
Log message:
Report memory used by listener structures.
---------------------- diff included ----------------------
Index: ircu2.10/ChangeLog
diff -u ircu2.10/ChangeLog:1.640 ircu2.10/ChangeLog:1.641
--- ircu2.10/ChangeLog:1.640 Mon May 30 14:07:33 2005
+++ ircu2.10/ChangeLog Mon May 30 14:11:38 2005
@@ -1,5 +1,10 @@
2005-05-30 Michael Poole <[EMAIL PROTECTED]>
+ * ircd/s_debug.c (count_memory): Use count_listener_memory() to
+ report memory used by listener structures.
+
+2005-05-30 Michael Poole <[EMAIL PROTECTED]>
+
* include/class.h (get_con_freq): Remove unused function.
* include/list.h (find_user_link): Remove unused function.
Index: ircu2.10/ircd/s_debug.c
diff -u ircu2.10/ircd/s_debug.c:1.38 ircu2.10/ircd/s_debug.c:1.39
--- ircu2.10/ircd/s_debug.c:1.38 Mon May 30 09:51:04 2005
+++ ircu2.10/ircd/s_debug.c Mon May 30 14:11:38 2005
@@ -19,7 +19,7 @@
*/
/** @file
* @brief Debug support for the ircd.
- * @version $Id: s_debug.c,v 1.38 2005/05/30 16:51:04 entrope Exp $
+ * @version $Id: s_debug.c,v 1.39 2005/05/30 21:11:38 entrope Exp $
*/
#include "config.h"
@@ -37,6 +37,7 @@
#include "ircd.h"
#include "jupe.h"
#include "list.h"
+#include "listener.h"
#include "motd.h"
#include "msgq.h"
#include "numeric.h"
@@ -223,6 +224,7 @@
wwu = 0, /* whowas users */
cl = 0, /* classes */
co = 0, /* conf lines */
+ listeners = 0, /* listeners */
memberships = 0; /* channel memberships */
int usi = 0, /* users invited */
@@ -247,6 +249,7 @@
dbufs_used = 0, /* memory used by dbufs */
msg_allocated = 0, /* memory used by struct Msg */
msgbuf_allocated = 0, /* memory used by struct MsgBuf */
+ listenersm = 0, /* memory used by listetners */
rm = 0, /* res memory used */
totcl = 0, totch = 0, totww = 0, tot = 0;
@@ -357,6 +360,9 @@
":Hash: client %d(%zu), chan is the same", HASHSIZE,
sizeof(void *) * HASHSIZE);
+ count_listener_memory(&listeners, &listenersm);
+ send_reply(cptr, SND_EXPLICIT | RPL_STATSDEBUG,
+ ":Listeners allocated %d(%zu)", listeners, listenersm);
/*
* NOTE: this count will be accurate only for the exact instant that this
* message is being sent, so the count is affected by the dbufs that
----------------------- End of diff -----------------------
_______________________________________________
Patches mailing list
[email protected]
http://undernet.sbg.org/mailman/listinfo/patches