]> jfr.im git - solanum.git/blobdiff - src/client.c
capability: add capability_index_list() to build a list of capabilities given an...
[solanum.git] / src / client.c
index 47ba0a450c29fa143e0e542c1a69ca90e054baaf..892c88cd5eb96a435112f478f177a4f4f5804908 100644 (file)
@@ -231,6 +231,7 @@ free_local_client(struct Client *client_p)
                rb_free(client_p->localClient->passwd);
        }
 
+       rb_free(client_p->localClient->auth_user);
        rb_free(client_p->localClient->challenge);
        rb_free(client_p->localClient->fullcaps);
        rb_free(client_p->localClient->opername);
@@ -255,6 +256,7 @@ free_client(struct Client *client_p)
        s_assert(&me != client_p);
        free_local_client(client_p);
        free_pre_client(client_p);
+       rb_free(client_p->certfp);
        rb_bh_free(client_heap, client_p);
 }
 
@@ -416,10 +418,10 @@ notify_banned_client(struct Client *client_p, struct ConfItem *aconf, int ban)
        const char *reason = NULL;
        const char *exit_reason = conn_closed;
 
-       if(ConfigFileEntry.kline_with_reason && !EmptyString(aconf->passwd))
+       if(ConfigFileEntry.kline_with_reason)
        {
-               reason = aconf->passwd;
-               exit_reason = aconf->passwd;
+               reason = get_user_ban_reason(aconf);
+               exit_reason = reason;
        }
        else
        {
@@ -585,7 +587,7 @@ check_xlines(void)
                                sendto_realops_snomask(SNO_GENERAL, L_ALL,
                                                     "XLINE over-ruled for %s, client is kline_exempt [%s]",
                                                     get_client_name(client_p, HIDE_IP),
-                                                    aconf->name);
+                                                    aconf->host);
                                continue;
                        }
 
@@ -1138,7 +1140,7 @@ exit_generic_client(struct Client *client_p, struct Client *source_p, struct Cli
        if(IsOper(source_p))
                rb_dlinkFindDestroy(source_p, &oper_list);
 
-       sendto_common_channels_local(source_p, ":%s!%s@%s QUIT :%s",
+       sendto_common_channels_local(source_p, NOCAPS, ":%s!%s@%s QUIT :%s",
                                     source_p->name,
                                     source_p->username, source_p->host, comment);
 
@@ -1670,14 +1672,14 @@ make_user(struct Client *client_p)
  * side effects - add's an Server information block to a client
  *                if it was not previously allocated.
  */
-server_t *
+struct Server *
 make_server(struct Client *client_p)
 {
-       server_t *serv = client_p->serv;
+       struct Server *serv = client_p->serv;
 
        if(!serv)
        {
-               serv = (server_t *) rb_malloc(sizeof(server_t));
+               serv = (struct Server *) rb_malloc(sizeof(struct Server));
                client_p->serv = serv;
        }
        return client_p->serv;