Skip to content

Commit

Permalink
auth_aka: do not wait for more AVs than needed
Browse files Browse the repository at this point in the history
  • Loading branch information
razvancrainea committed Mar 19, 2024
1 parent 00c4cbe commit 9b87a86
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions modules/auth_aka/auth_aka.c
Original file line number Diff line number Diff line change
Expand Up @@ -1022,6 +1022,12 @@ static int aka_challenge_async_resume_handle(struct sip_msg *msg, void *_param,
int left, err_count;
struct aka_async_param *param = _param;

/* if this handling has already been completed, drop it */
if (param->avs_fetched + param->avs_error >= param->avs_count) {
left = 0;
goto end;
}

/* check to see how many events we got */
param->avs_fetched += aka_avs_get_new(param->user, &param->algmask,
param->avs + param->avs_fetched, param->avs_count - param->avs_fetched, &err_count);
Expand Down

0 comments on commit 9b87a86

Please sign in to comment.