Skip to content

Commit

Permalink
Fix OpenRCT2#13552: Incorrect value for highscore pointer
Browse files Browse the repository at this point in the history
This was causing an invalid pointer dereference
  • Loading branch information
duncanspumpkin committed Dec 8, 2020
1 parent 14ed150 commit 7bab63e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/openrct2/scenario/ScenarioRepository.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ class ScenarioFileIndex final : public FileIndex<scenario_index_entry>
{
private:
static constexpr uint32_t MAGIC_NUMBER = 0x58444953; // SIDX
static constexpr uint16_t VERSION = 4;
static constexpr uint16_t VERSION = 5;
static constexpr auto PATTERN = "*.sc4;*.sc6;*.sea";

public:
Expand Down
2 changes: 1 addition & 1 deletion src/openrct2/scenario/ScenarioRepository.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ struct scenario_index_entry
uint8_t objective_arg_1;
int32_t objective_arg_2;
int16_t objective_arg_3;
scenario_highscore_entry* highscore;
scenario_highscore_entry* highscore = nullptr;

utf8 internal_name[64]; // Untranslated name
utf8 name[64]; // Translated name
Expand Down

0 comments on commit 7bab63e

Please sign in to comment.