Skip to content

Commit

Permalink
test: fix memory leak in unit tests
Browse files Browse the repository at this point in the history
Signed-off-by: William Henderson <[email protected]>
  • Loading branch information
w-henderson committed Jul 31, 2023
1 parent 89adade commit adc9cbb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/unit-tests.c
Original file line number Diff line number Diff line change
Expand Up @@ -518,6 +518,11 @@ static int
teardown_test_setup_migration(void **state) {
struct test_setup_migr_reg_dat *p = *state;
vfu_destroy_ctx(p->v);

if (LAST_WRITE != NULL) {
free(LAST_WRITE);
}

return 0;
}

Expand Down

0 comments on commit adc9cbb

Please sign in to comment.