Skip to content

Commit

Permalink
Use ref
Browse files Browse the repository at this point in the history
  • Loading branch information
ioan-chera committed Nov 4, 2023
1 parent d8f763a commit e9d32c2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Instance.h
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ class Instance
void EmptyLump(const char *name) const;
void FreshLevel();
void LoadBehavior(const Wad_file *load_wad);
void LoadHeader(const Wad_file *load_wad);
void LoadHeader(const Wad_file &load_wad);
void LoadLineDefs(const Wad_file *load_wad);
void LoadLineDefs_Hexen(const Wad_file *load_wad);
void LoadScripts(const Wad_file *load_wad);
Expand Down
6 changes: 3 additions & 3 deletions src/m_loadsave.cc
Original file line number Diff line number Diff line change
Expand Up @@ -575,9 +575,9 @@ void Instance::ValidateSectorRef(SideDef *sd, int num)
}


void Instance::LoadHeader(const Wad_file *load_wad)
void Instance::LoadHeader(const Wad_file &load_wad)
{
Lump_c *lump = load_wad->GetLump(load_wad->LevelHeader(loading_level));
Lump_c *lump = load_wad.GetLump(load_wad.LevelHeader(loading_level));

int length = lump->Length();

Expand Down Expand Up @@ -957,7 +957,7 @@ void Instance::LoadLevelNum(const Wad_file *wad, int lev_num)
bad_sector_refs = 0;
bad_sidedef_refs = 0;

LoadHeader(wad);
LoadHeader(*wad);

if (loaded.levelFormat == MapFormat::udmf)
{
Expand Down

0 comments on commit e9d32c2

Please sign in to comment.