Fix missing calls to va_end in libunicode

This commit is contained in:
Ivan Komissarov 2025-01-06 16:36:48 +03:00 committed by Saúl Ibarra Corretgé
parent af16390b85
commit 84d11c4f69

View file

@ -1542,11 +1542,13 @@ static int unicode_prop_ops(CharRange *cr, ...)
}
}
done:
va_end(ap);
assert(stack_len == 1);
ret = cr_copy(cr, &stack[0]);
cr_free(&stack[0]);
return ret;
fail:
va_end(ap);
for(i = 0; i < stack_len; i++)
cr_free(&stack[i]);
return -1;