From 6b73b99f7c5af48c83c30334c20fd07029628a1e Mon Sep 17 00:00:00 2001 From: "Kevin L. Mitchell" Date: Tue, 10 Apr 2007 14:53:03 +0000 Subject: [PATCH] Author: Kev Log message: Don't allow G-lines to have 0 lastmod--return a "need more params" message if lastmod evaluates to 0. This solves the bug where not passing a lastmod resulted in an assertion failure in gline_propagate(). git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/branches/u2_10_12_branch@1799 c9e4aea6-c8fd-4c43-8297-357d70d61c8c --- ChangeLog | 4 ++++ ircd/m_gline.c | 3 +++ 2 files changed, 7 insertions(+) diff --git a/ChangeLog b/ChangeLog index 7ed903a..7c19be4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2007-04-10 Kevin L. Mitchell + + * ircd/m_gline.c (ms_gline): lastmod must be non-zero + 2007-04-04 Michael Poole * ircd/s_conf.c (rehash): Restart resolver after reading the diff --git a/ircd/m_gline.c b/ircd/m_gline.c index 18c1855..1fa28dd 100644 --- a/ircd/m_gline.c +++ b/ircd/m_gline.c @@ -306,6 +306,9 @@ ms_gline(struct Client *cptr, struct Client *sptr, int parc, char *parv[]) } } + if (!lastmod) /* must have a lastmod parameter by now */ + return need_more_params(sptr, "GLINE"); + Debug((DEBUG_DEBUG, "I have a global G-line I am acting upon now; " "target %s, mask %s, operforce %s, action %s, expire %Tu, " "lastmod %Tu, lifetime %Tu, reason: %s; gline %s! (fields " -- 2.20.1