-void connection_del(connection_t *c)
-{
- cp();
-
- avl_delete(connection_tree, c);
-}
-
-void dump_connections(void)
-{
- avl_node_t *node;
- connection_t *c;
-
- cp();
-
- logger(LOG_DEBUG, _("Connections:"));
-
- for(node = connection_tree->head; node; node = node->next) {
- c = (connection_t *) node->data;
- logger(LOG_DEBUG, _(" %s at %s options %lx socket %d status %04x"),
- c->name, c->hostname, c->options, c->socket, c->status);
+void connection_del(connection_t *c) {
+ for(list_node_t *node = connection_list->head; node; node = node->next) {
+ if(node->data == c) {
+ list_delete_node(connection_list, node);
+ return;
+ }