Jacob Garber has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/32841
Change subject: util/romcc: Free variable after it is used ......................................................................
util/romcc: Free variable after it is used
Free 'arg_type' after it is used to prevent a memory leak.
Found-by: Coverity Scan CID 1129114 Signed-off-by: Jacob Garber jgarber1@ualberta.ca Change-Id: I5e8661547bb7623463ed23fc45269049ffb8c50e --- M util/romcc/romcc.c 1 file changed, 1 insertion(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/41/32841/1
diff --git a/util/romcc/romcc.c b/util/romcc/romcc.c index 43be171..e40c7d0 100644 --- a/util/romcc/romcc.c +++ b/util/romcc/romcc.c @@ -11236,6 +11236,7 @@
arg_type = arithmetic_result(state, left, right); sign = is_signed(arg_type); + xfree(arg_type); op = -1; switch(tok) { case TOK_LESS: op = sign? OP_SLESS : OP_ULESS; break;