aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTrazom62 <none@none>2010-01-18 23:45:08 +0100
committerTrazom62 <none@none>2010-01-18 23:45:08 +0100
commit1c5060f4555c1bb58fd6834189d58ce723b59ccf (patch)
treec097443bc6d38aadf90da96ec685137937fa9fc8 /src
parenta1bbbd1421d29edd02feb2e19df8b07c9484f59d (diff)
Fix crash in OutdoorPvPWG::UpdateQuestGiverPosition
Fixes issue #342. --HG-- branch : trunk
Diffstat (limited to 'src')
-rw-r--r--src/game/OutdoorPvPWG.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/game/OutdoorPvPWG.cpp b/src/game/OutdoorPvPWG.cpp
index bc531a4032a..4d4c6590b04 100644
--- a/src/game/OutdoorPvPWG.cpp
+++ b/src/game/OutdoorPvPWG.cpp
@@ -678,7 +678,10 @@ void OutdoorPvPWG::OnCreatureCreate(Creature *creature, bool add)
break;
}
case CREATURE_QUESTGIVER:
- m_questgivers[creature->GetDBTableGUIDLow()] = creature;
+ if (add)
+ m_questgivers[creature->GetDBTableGUIDLow()] = creature;
+ else
+ m_questgivers.erase(creature->GetDBTableGUIDLow());
break;
case CREATURE_ENGINEER:
for (OutdoorPvP::OPvPCapturePointMap::iterator itr = m_capturePoints.begin(); itr != m_capturePoints.end(); ++itr)