Fix a mem leak in cmd_anal.c

This commit is contained in:
Fangrui Song 2017-08-27 17:48:17 -07:00 committed by Anton Kochkov
parent 4331773b3f
commit 6c0b4aa139

View File

@ -3810,6 +3810,7 @@ static void cmd_anal_esil(RCore *core, const char *input) {
}
ret = r_core_esil_step (core, UT64_MAX, NULL, NULL);
r_anal_op_free (op);
op = NULL;
if (core->anal->esil->trap || core->anal->esil->trap_code) {
break;
}
@ -3824,6 +3825,9 @@ static void cmd_anal_esil(RCore *core, const char *input) {
addr = newaddr;
}
}
if (op) {
r_anal_op_free (op);
}
} else {
// "aec" -> continue until ^C
// "aecu" -> until address