Skip to content

Commit

Permalink
aaa_diameter: properly pass reply return code
Browse files Browse the repository at this point in the history
  • Loading branch information
razvancrainea authored and bogdan-iancu committed Apr 18, 2024
1 parent ac6eed5 commit 78cbbd2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions modules/aaa_diameter/aaa_diameter.c
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,10 @@ static int dm_send_request_async_reply(int fd,
goto error;
}
ret = _dm_get_message_response(amsg->cond, &rpl_avps);
if (ret == 0)
ret = 1;
else
LM_ERR("Diameter request failed\n");
if (ret > 0 && amsg->ret && rpl_avps) {
val.rs.s = rpl_avps;
val.rs.len = strlen(rpl_avps);
Expand Down
2 changes: 1 addition & 1 deletion modules/aaa_diameter/dm_impl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1930,7 +1930,7 @@ int _dm_get_message_response(struct dm_cond *cond, char **rpl_avps)

if (cond->is_error)
return -1;
return 1;
return 0;
}


Expand Down

0 comments on commit 78cbbd2

Please sign in to comment.