Skip to content

Commit

Permalink
Fixed Null Ptr (#139)
Browse files Browse the repository at this point in the history
  • Loading branch information
jshplayer authored Jul 19, 2023
1 parent 34bdfc6 commit 8b9479f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/AutoBalance.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -550,6 +550,17 @@ void LoadMapSettings(Map* map)
// create an InstanceMap object
InstanceMap* instanceMap = map->ToInstanceMap();

//check for null pointer
if (!map)
{
return;
}

if (!map->IsDungeon() && !map->IsRaid())
{
return;
}

// should the map be enabled at all?
mapABInfo->enabled = ShouldMapBeEnabled(map);

Expand Down

0 comments on commit 8b9479f

Please sign in to comment.