Skip to content

Commit

Permalink
Set transition_map->states/transition size to 0 on fini (#729)
Browse files Browse the repository at this point in the history
Signed-off-by: Stephen Brawner <brawner@gmail.com>
  • Loading branch information
brawner authored Aug 12, 2020
1 parent c749682 commit f90c01c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions rcl_lifecycle/src/transition_map.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,11 @@ rcl_lifecycle_transition_map_fini(
// free the primary states
allocator->deallocate(transition_map->states, allocator->state);
transition_map->states = NULL;
transition_map->states_size = 0;
// free the tansitions
allocator->deallocate(transition_map->transitions, allocator->state);
transition_map->transitions = NULL;
transition_map->transitions_size = 0;

return fcn_ret;
}
Expand Down

0 comments on commit f90c01c

Please sign in to comment.