Core: Fixed uninitialized variable warnings

--HG--
branch : trunk
This commit is contained in:
Shauren
2010-12-14 15:58:45 +01:00
parent 0c04b178db
commit f4581f67b8
6 changed files with 12 additions and 8 deletions
+4 -3
View File
@@ -1036,8 +1036,8 @@ valid examples:
int32 propertyId = 0;
bool negativeNumber = false;
char c;
for (uint8 i=0; i<randomPropertyPosition; ++i)
char c = '\0';
for (uint8 i = 0; i < randomPropertyPosition; ++i)
{
propertyId = 0;
negativeNumber = false;
@@ -1053,6 +1053,7 @@ valid examples:
return false;
}
}
if (negativeNumber)
propertyId *= -1;
@@ -1070,7 +1071,7 @@ valid examples:
}
// ignore other integers
while ((c >='0' && c <= '9') || c == ':')
while ((c >= '0' && c <= '9') || c == ':')
{
reader.ignore(1);
c = reader.peek();
+1 -1
View File
@@ -4410,7 +4410,7 @@ bool ChatHandler::HandleChannelSetOwnership(const char *args)
return false;
Player *player = m_session->GetPlayer();
Channel *chn;
Channel *chn = NULL;
if (ChannelMgr* cMgr = channelMgr(player->GetTeam()))
chn = cMgr->GetChannel(channel, player);