mirror of
https://gitlab.xiph.org/xiph/icecast-server.git
synced 2025-01-03 14:56:34 -05:00
Fix: Actually destroy clients on if auth has release callback
This commit is contained in:
parent
1b5572f700
commit
f6d269c80d
@ -486,6 +486,13 @@ static void auth_add_client(auth_t *auth, client_t *client, void (*on_no_match)(
|
||||
queue_auth_client(auth_user);
|
||||
}
|
||||
|
||||
static void __auth_on_result_destroy_client(client_t *client, void *userdata, auth_result result)
|
||||
{
|
||||
(void)userdata, (void)result;
|
||||
|
||||
client_destroy(client);
|
||||
}
|
||||
|
||||
/* determine whether we need to process this client further. This
|
||||
* involves any auth exit, typically for external auth servers.
|
||||
*/
|
||||
@ -496,6 +503,7 @@ int auth_release_client (client_t *client) {
|
||||
if (client->auth && client->auth->release_client) {
|
||||
auth_client *auth_user = auth_client_setup(client);
|
||||
auth_user->process = auth_remove_client;
|
||||
auth_user->on_result = __auth_on_result_destroy_client;
|
||||
queue_auth_client(auth_user);
|
||||
return 1;
|
||||
} else if (client->auth) {
|
||||
|
Loading…
Reference in New Issue
Block a user