translate.c: Avoid refleak when checking for a translation path

Change-Id: Idbd61ff77545f4a78b06a5064b55112e774b70e6
This commit is contained in:
Sean Bright 2021-04-30 16:21:55 -04:00
parent 0eb5c58bd4
commit d72c7d2d66
1 changed files with 1 additions and 1 deletions

View File

@ -1527,7 +1527,7 @@ static void check_translation_path(
destination format. */
for (i = ast_format_cap_count(result) - 1; 0 <= i; i--) {
int index, src_index;
struct ast_format *fmt = ast_format_cap_get_format(result, i);
RAII_VAR(struct ast_format *, fmt, ast_format_cap_get_format(result, i), ao2_cleanup);
if (ast_format_get_type(fmt) != type) {
continue;