mirror of
https://github.com/pissnet/angiosperm.git
synced 2025-08-12 18:31:36 +01:00
authd: change to lists instead of dictionaries for various things
Iteration is the primary thing done on these, so using a dictionary doesn't help a lot. Furthermore (and most importantly), they are not safe to delete from.
This commit is contained in:
parent
d71787ab69
commit
49fd293f20
6 changed files with 112 additions and 75 deletions
authd/providers
|
@ -112,11 +112,12 @@ client_success(struct auth_client *auth)
|
|||
static void
|
||||
rdns_destroy(void)
|
||||
{
|
||||
struct auth_client *auth;
|
||||
rb_dictionary_iter iter;
|
||||
rb_dlink_node *ptr, *nptr;
|
||||
|
||||
RB_DICTIONARY_FOREACH(auth, &iter, auth_clients)
|
||||
RB_DLINK_FOREACH_SAFE(ptr, nptr, auth_clients.head)
|
||||
{
|
||||
struct auth_client *auth = ptr->data;
|
||||
|
||||
if(get_provider_data(auth, SELF_PID) != NULL)
|
||||
client_fail(auth, REPORT_FAIL);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue