]> jfr.im git - irc/charybdis-ircd/charybdis.git/commitdiff
callerid: don't clobber other modules
authorAriadne Conill <redacted>
Fri, 26 Jun 2020 19:05:17 +0000 (13:05 -0600)
committerAriadne Conill <redacted>
Thu, 9 Jul 2020 22:06:33 +0000 (16:06 -0600)
modules/um_callerid.c

index 371c0c7dee33d1b6e5a0ff64b3fe7c1a68824759..452b7b96364dc940c0130153879af44e0315334d 100644 (file)
@@ -154,6 +154,9 @@ h_can_invite(void *vdata)
        struct Client *source_p = data->client;
        struct Client *target_p = data->target;
 
+       if (data->approved)
+               return;
+
        if (!add_callerid_accept_for_source(MESSAGE_TYPE_PRIVMSG, source_p, target_p))
        {
                data->approved = ERR_TARGUMODEG;
@@ -176,6 +179,9 @@ h_hdl_privmsg_user(void *vdata)
        struct Client *source_p = data->source_p;
        struct Client *target_p = data->target_p;
 
+       if (data->approved)
+               return;
+
        if (!add_callerid_accept_for_source(msgtype, source_p, target_p))
        {
                data->approved = ERR_TARGUMODEG;