Skip to content

Commit

Permalink
Fix read after free bug
Browse files Browse the repository at this point in the history
  • Loading branch information
JFreegman committed Dec 21, 2023
1 parent 5f4d9ea commit 8c74aed
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/game_snake.c
Original file line number Diff line number Diff line change
Expand Up @@ -1164,7 +1164,6 @@ int snake_initialize(GameData *game, bool is_online, bool self_host)
int err = -4;

if (state->snake == NULL) {
free(state);
goto on_error;
}

Expand Down

0 comments on commit 8c74aed

Please sign in to comment.