projects
/
ircu2.10.12-pk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improve the clean-up of outdated IAuth instances on rehash (SF bug #2789656).
[ircu2.10.12-pk.git]
/
ircd
/
motd.c
diff --git
a/ircd/motd.c
b/ircd/motd.c
index 8359f21426648689e4d0104e987a7630d8def482..bdad75eeb5bb5c20d7d3679b0dcc36461b2c4341 100644
(file)
--- a/
ircd/motd.c
+++ b/
ircd/motd.c
@@
-34,6
+34,7
@@
#include "ircd.h"
#include "ircd_alloc.h"
#include "ircd_features.h"
#include "ircd.h"
#include "ircd_alloc.h"
#include "ircd_features.h"
+#include "ircd_log.h"
#include "ircd_reply.h"
#include "ircd_string.h"
#include "match.h"
#include "ircd_reply.h"
#include "ircd_string.h"
#include "match.h"
@@
-46,7
+47,7
@@
#include "s_stats.h"
#include "send.h"
#include "s_stats.h"
#include "send.h"
-#include <assert.h>
+/* #include <assert.h> -- Now using assert in ircd_log.h */
#include <errno.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <stdlib.h>
#include <string.h>
@@
-93,6
+94,8
@@
motd_create(const char *hostmask, const char *path, int maxcount)
if (hostmask != NULL)
DupString(tmp->hostmask, hostmask);
if (hostmask != NULL)
DupString(tmp->hostmask, hostmask);
+ else
+ tmp->hostmask = NULL;
DupString(tmp->path, path);
tmp->maxcount = maxcount;
DupString(tmp->path, path);
tmp->maxcount = maxcount;
@@
-444,10
+447,10
@@
motd_memory_count(struct Client *cptr)
struct Motd *ptr;
struct MotdCache *cache;
unsigned int mt = 0, /* motd count */
struct Motd *ptr;
struct MotdCache *cache;
unsigned int mt = 0, /* motd count */
- mtm = 0, /* memory consumed by motd */
mtc = 0, /* motd cache count */
mtc = 0, /* motd cache count */
- mtcm = 0, /* memory consumed by motd cache */
mtf = 0; /* motd free list count */
mtf = 0; /* motd free list count */
+ size_t mtm = 0, /* memory consumed by motd */
+ mtcm = 0; /* memory consumed by motd cache */
if (MotdList.local)
{
mt++;
if (MotdList.local)
{
mt++;