Skip to content

Commit

Permalink
emu_shellcode - free current_pos_ti_diff if we continue within the loop
Browse files Browse the repository at this point in the history
  • Loading branch information
common committed Dec 3, 2010
1 parent 4811f65 commit 9fb7464
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/emu_shellcode.c
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,7 @@ int32_t emu_shellcode_run_and_track(struct emu *e,
if( emu_hashtable_search(known_positions, (void *)(uintptr_t)(uint32_t)current_offset) != NULL)
{
logDebug(e, "Known %p %x\n", eti, eti->eip);
emu_tracking_info_free(eti);
break;
}

Expand All @@ -309,12 +310,14 @@ int32_t emu_shellcode_run_and_track(struct emu *e,
{
logDebug(e, "Known Again %p %x\n", current_pos_satii, current_pos_satii->eip);
current_pos_v->color = red;
emu_tracking_info_free(current_pos_ti_diff);
continue;
}

if (current_pos_v->color == red)
{
logDebug(e, "is red %p %x: %s\n", (uintptr_t)current_pos_v, current_pos_satii->eip, current_pos_satii->instrstring);
emu_tracking_info_free(current_pos_ti_diff);
continue;
}

Expand Down

0 comments on commit 9fb7464

Please sign in to comment.