aboutsummaryrefslogtreecommitdiff
path: root/src/game/Transports.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/Transports.cpp')
-rw-r--r--src/game/Transports.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/game/Transports.cpp b/src/game/Transports.cpp
index f0efef5ee20..8e7eb82597e 100644
--- a/src/game/Transports.cpp
+++ b/src/game/Transports.cpp
@@ -33,7 +33,7 @@
void MapManager::LoadTransports()
{
- QueryResult *result = WorldDatabase.Query("SELECT entry, name, period FROM transports");
+ QueryResult_AutoPtr result = WorldDatabase.Query("SELECT entry, name, period FROM transports");
uint32 count = 0;
@@ -111,7 +111,6 @@ void MapManager::LoadTransports()
//t->GetMap()->Add<GameObject>((GameObject *)t);
++count;
} while(result->NextRow());
- delete result;
sLog.outString();
sLog.outString( ">> Loaded %u transports", count );
@@ -130,8 +129,6 @@ void MapManager::LoadTransports()
sLog.outErrorDb("Transport %u '%s' have record (GUID: %u) in `gameobject`. Transports DON'T must have any records in `gameobject` or its behavior will be unpredictable/bugged.",entry,name.c_str(),guid);
}
while(result->NextRow());
-
- delete result;
}
}