From: Nick Porter Date: Fri, 15 Apr 2022 11:31:44 +0000 (+0100) Subject: Avoid null dereference. CID #1504060 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6ea1cd37ec9987f69b95a2c9e503d75ad14fd830;p=thirdparty%2Ffreeradius-server.git Avoid null dereference. CID #1504060 --- diff --git a/src/lib/io/master.c b/src/lib/io/master.c index ad1f6d57df0..4fe70d90715 100644 --- a/src/lib/io/master.c +++ b/src/lib/io/master.c @@ -795,7 +795,7 @@ static fr_io_connection_t *fr_io_connection_alloc(fr_io_instance_t const *inst, "Closing it, and diuscarding all packets for connection %s.", inst->app_io->common.name, connection->name); pthread_mutex_lock(&client->mutex); - (void) fr_hash_table_delete(client->ht, connection); + if (client->ht) (void) fr_hash_table_delete(client->ht, connection); pthread_mutex_unlock(&client->mutex); cleanup: