Fix a mem leak in OutdoorPvPMgr's destructor.
log: ==12080== 1,680 (168 direct, 1,512 indirect) bytes in 1 blocks are definitely lost in loss record 106 of 253 ==12080== at 0x4C2626C: operator new(unsigned long) (vg_replace_malloc.c:230) ==12080== by 0xA63AE9: OutdoorPvPMgr::InitOutdoorPvP() (OutdoorPvPMgr.cpp:51) ==12080== by 0xC01BDA: World::SetInitialWorldSettings() (World.cpp:1650) ==12080== by 0x808EF6: Master::Run() (Master.cpp:235) ==12080== by 0x8083B5: main (Main.cpp:154) --HG-- branch : trunk
This commit is contained in:
@@ -42,6 +42,7 @@ OutdoorPvPMgr::~OutdoorPvPMgr()
|
||||
for (OutdoorPvPSet::iterator itr = m_OutdoorPvPSet.begin(); itr != m_OutdoorPvPSet.end(); ++itr)
|
||||
{
|
||||
(*itr)->DeleteSpawns();
|
||||
delete *itr;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user