Skip to content

Commit

Permalink
Fix typo in savecompat.cpp
Browse files Browse the repository at this point in the history
It caused a use-after-free bug
  • Loading branch information
psampathkumar authored and jwrober committed Jul 16, 2022
1 parent 137068d commit 8ff4ca0
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions server/savegame/savecompat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1441,8 +1441,6 @@ static void insert_server_side_agent(struct loaddata *loading,
secfile_insert_str_vec(loading->file, modname, SSA_COUNT,
"savefile.server_side_agent_list");
delete[] modname;
secfile_insert_str_vec(loading->file, modname, SSA_COUNT,
"savefile.server_side_agent_list");

// Insert server_side_agent unit field.
player_slots_iterate(pslot)
Expand Down

0 comments on commit 8ff4ca0

Please sign in to comment.