Add comments explaining why we set banstr to NULL in two places.
[ircu2.10.12-pk.git] / ircd / m_clearmode.c
index f3524307a0cf1fda9b4df970a53f1ba0de45c885..c8d3516be58eaa1b85b6db2076c2242bbd24af2c 100644 (file)
@@ -181,7 +181,8 @@ do_clearmode(struct Client *cptr, struct Client *sptr, struct Channel *chptr,
 
       modebuf_mode_string(&mbuf, MODE_DEL | MODE_BAN, /* delete ban */
                          link->banstr, 1);
-      link->banstr = NULL;
+      link->banstr = NULL; /* modebuf_mode_string() gave ownership of
+                            * banstr to mbuf */
       free_ban(link);
     }