]> jfr.im git - irc/charybdis-ircd/charybdis.git/commitdiff
exit_unknown_client: don't delete servers from the client hash
authorSimon Arlott <sa.me.uk>
Thu, 24 Aug 2017 19:07:31 +0000 (20:07 +0100)
committerSimon Arlott <sa.me.uk>
Thu, 24 Aug 2017 19:09:05 +0000 (20:09 +0100)
Outgoing servers are not added to the client hash until they reach
IsServer() status, so if they're unknown when they exit then don't
attempt to delete them.

ircd/client.c

index a4ee0cac292de11db69543dc75f22290100d256f..43e2e032e40c86d1e669d50b0bbecfc07b5154ce 100644 (file)
@@ -1383,7 +1383,8 @@ exit_unknown_client(struct Client *client_p, /* The local client originating the
                del_from_id_hash(source_p->id, source_p);
 
        del_from_hostname_hash(source_p->host, source_p);
-       del_from_client_hash(source_p->name, source_p);
+       if (!IsAnyServer(source_p))
+               del_from_client_hash(source_p->name, source_p);
        remove_client_from_list(source_p);
        SetDead(source_p);
        rb_dlinkAddAlloc(source_p, &dead_list);