summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-06-04 13:31:17 +0000
committermichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-06-04 13:31:17 +0000
commit6fc638ed61aad91989c9fa4fa1b15a86708aeb9f (patch)
tree50e79310f5eb2a3f6931a60b7c9e82876d36cdcc /src
parent9b9d8e479301106c9d6db74061fbd224958f810d (diff)
- motd.c:motd_destroy() don't attempt to unlink a local/remote motd
from MotdList.other git-svn-id: svn://svn.ircd-hybrid.org/svnroot/ircd-hybrid/branches/8.1.x@2192 82007160-df01-0410-b94d-b575c5fd34c7
Diffstat (limited to 'src')
-rw-r--r--src/motd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/motd.c b/src/motd.c
index 21218e3..138b9b3 100644
--- a/src/motd.c
+++ b/src/motd.c
@@ -210,7 +210,6 @@ motd_destroy(struct Motd *motd)
if (motd->cache) /* drop the cache */
motd_decache(motd);
- dlinkDelete(&motd->node, &MotdList.other);
MyFree(motd->path); /* we always must have a path */
MyFree(motd->hostmask);
MyFree(motd);
@@ -411,7 +410,10 @@ motd_clear(void)
motd_decache(MotdList.remote);
DLINK_FOREACH_SAFE(ptr, ptr_next, MotdList.other.head) /* destroy other MOTDs */
+ {
+ dlinkDelete(ptr, &MotdList.other);
motd_destroy(ptr->data);
+ }
/* now recache local and remote MOTDs */
motd_cache(MotdList.local);