]> jfr.im git - solanum.git/blobdiff - ircd/authproc.c
ircd: do nothing in client_release_connids if !MyConnect
[solanum.git] / ircd / authproc.c
index a07db671eb32aa4b1e064108f136baef7d728512..6328409f52293ec937b1061c11f8b1471fdf85e3 100644 (file)
@@ -284,7 +284,7 @@ parse_authd_reply(rb_helper * helper)
                struct authd_cb *cmd;
 
                parc = rb_string_to_array(buf, parv, MAXPARA+1);
-               cmd = &authd_cmd_tab[*parv[0]];
+               cmd = &authd_cmd_tab[(unsigned char)*parv[0]];
                if(cmd->fn != NULL)
                {
                        if(cmd->min_parc > parc)
@@ -461,6 +461,7 @@ authd_decide_client(struct Client *client_p, const char *ident, const char *host
        if(*ident != '*')
        {
                rb_strlcpy(client_p->username, ident, sizeof(client_p->username));
+               SetGotId(client_p);
                ServerStats.is_asuc++;
        }
        else
@@ -562,6 +563,7 @@ add_blacklist(const char *host, const char *reason, uint8_t iptype, rb_dlink_lis
        if(s)
                filterbuf[s - 1] = '\0';
 
+       stats->host = rb_strdup(host);
        stats->iptype = iptype;
        stats->hits = 0;
        rb_dictionary_add(bl_stats, host, stats);
@@ -577,6 +579,7 @@ del_blacklist(const char *host)
        if(stats != NULL)
        {
                rb_dictionary_delete(bl_stats, host);
+               rb_free(stats->host);
                rb_free(stats);
        }
 
@@ -592,8 +595,9 @@ del_blacklist_all(void)
 
        RB_DICTIONARY_FOREACH(stats, &iter, bl_stats)
        {
+               rb_dictionary_delete(bl_stats, stats->host);
+               rb_free(stats->host);
                rb_free(stats);
-               rb_dictionary_delete(bl_stats, iter.cur->key);
        }
 
        rb_helper_write(authd_helper, "O rbl_del_all");
@@ -654,7 +658,7 @@ create_opm_listener(const char *ip, uint16_t port)
        }
 
        conf_create_opm_listener(ip, port);
-       rb_helper_write(authd_helper, "O opm_listener %s %hu", ip, port);
+       rb_helper_write(authd_helper, "O opm_listener %s %hu", ipbuf, port);
 }
 
 void