Skip to content

Commit 73f959f

Browse files
author
ionutrazvanionita
committed
[bugfix]on resume fetch index from async context
1 parent 0108065 commit 73f959f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/buildreq.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ int rc_aaa_async (rc_handle *rh, uint32_t client_port, VALUE_PAIR *send, VALUE_P
385385
/*rc_receive async name*/
386386
int rc_aaa_receive_async(SEND_CONTEXT **ctx, VALUE_PAIR **received, int request_type)
387387
{
388-
int i, j;
388+
int i;
389389
int result;
390390

391391
if (*ctx == NULL) {
@@ -396,6 +396,7 @@ int rc_aaa_receive_async(SEND_CONTEXT **ctx, VALUE_PAIR **received, int request_
396396
result = rc_receive_async(ctx);
397397

398398
if (result != READBLOCK_RC) {
399+
i = (*ctx)->idx;
399400
(*ctx)->aaaserver->deadtime_ends[i] = -1;
400401
if (request_type != PW_ACCOUNTING_REQUEST) {
401402
*received = (*ctx)->data->receive_pairs;

0 commit comments

Comments
 (0)