Some warning fix
Tab to spaces Remove trailing spaces --HG-- branch : trunk
This commit is contained in:
@@ -772,7 +772,7 @@ void WorldSession::SendListInventory(uint64 vendorguid)
|
||||
// reputation discount
|
||||
int32 price = uint32(floor(pProto->BuyPrice * discountMod));
|
||||
|
||||
data << uint32(vendorslot+1); // client expects counting to start at 1
|
||||
data << uint32(vendorslot+1); // client expects counting to start at 1
|
||||
data << uint32(crItem->item);
|
||||
data << uint32(pProto->DisplayInfoID);
|
||||
data << int32(crItem->maxcount <= 0 ? 0xFFFFFFFF : pCreature->GetVendorItemCurrentCount(crItem));
|
||||
|
||||
@@ -323,7 +323,7 @@ struct npc_muglashAI : public npc_escortAI
|
||||
}
|
||||
}
|
||||
|
||||
void Aggro(Unit* pWho)
|
||||
void Aggro(Unit* /*pWho*/)
|
||||
{
|
||||
if (HasEscortState(STATE_ESCORT_PAUSED))
|
||||
{
|
||||
@@ -340,7 +340,7 @@ struct npc_muglashAI : public npc_escortAI
|
||||
m_bIsBrazierExtinguished = false;
|
||||
}
|
||||
|
||||
void JustDied(Unit* pKiller)
|
||||
void JustDied(Unit* /*pKiller*/)
|
||||
{
|
||||
Player* pPlayer = GetPlayerForEscort();
|
||||
if (HasEscortState(STATE_ESCORT_ESCORTING))
|
||||
@@ -420,7 +420,7 @@ bool QuestAccept_npc_muglash(Player* pPlayer, Creature* pCreature, const Quest*
|
||||
}
|
||||
|
||||
|
||||
bool GOHello_go_naga_brazier(Player* pPlayer, GameObject* pGo)
|
||||
bool GOHello_go_naga_brazier(Player* /*pPlayer*/, GameObject* pGo)
|
||||
{
|
||||
if (Creature* pCreature = GetClosestCreatureWithEntry(pGo, NPC_MUGLASH, INTERACTION_DISTANCE*2))
|
||||
{
|
||||
|
||||
@@ -157,7 +157,7 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit *pWho)
|
||||
void EnterCombat(Unit * /*pWho*/)
|
||||
{
|
||||
DoScriptText(SAY_AGGRO, me);
|
||||
if (pInstance)
|
||||
@@ -323,7 +323,7 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
}
|
||||
}
|
||||
|
||||
void JustDied(Unit *pKiller)
|
||||
void JustDied(Unit * /*pKiller*/)
|
||||
{
|
||||
DoScriptText(SAY_DEATH, me);
|
||||
lSummons.DespawnAll();
|
||||
|
||||
@@ -1021,15 +1021,18 @@ enum eScourgeEnclosure
|
||||
|
||||
bool GOHello_go_scourge_enclosure(Player *pPlayer, GameObject *pGO)
|
||||
{
|
||||
Creature *pGymerDummy;
|
||||
if (pPlayer->GetQuestStatus(QUEST_OUR_ONLY_HOPE) == QUEST_STATUS_INCOMPLETE &&
|
||||
(pGymerDummy = pGO->FindNearestCreature(NPC_GYMER_DUMMY,20.0f)))
|
||||
|
||||
if (pPlayer->GetQuestStatus(QUEST_OUR_ONLY_HOPE) == QUEST_STATUS_INCOMPLETE)
|
||||
{
|
||||
Creature *pGymerDummy = pGO->FindNearestCreature(NPC_GYMER_DUMMY,20.0f);
|
||||
if (pGymerDummy)
|
||||
{
|
||||
pGO->UseDoorOrButton();
|
||||
pPlayer->KilledMonsterCredit(pGymerDummy->GetEntry(),pGymerDummy->GetGUID());
|
||||
pGymerDummy->CastSpell(pGymerDummy, 55529, true);
|
||||
pGymerDummy->DisappearAndDie();
|
||||
pGO->UseDoorOrButton();
|
||||
pPlayer->KilledMonsterCredit(pGymerDummy->GetEntry(),pGymerDummy->GetGUID());
|
||||
pGymerDummy->CastSpell(pGymerDummy, 55529, true);
|
||||
pGymerDummy->DisappearAndDie();
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -442,7 +442,7 @@ struct npc_ogre_bruteAI : public ScriptedAI
|
||||
}
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 id)
|
||||
void MovementInform(uint32 /*type*/, uint32 id)
|
||||
{
|
||||
Player* pPlayer = Unit::GetPlayer(PlayerGUID);
|
||||
if (id == 1)
|
||||
@@ -459,7 +459,7 @@ struct npc_ogre_bruteAI : public ScriptedAI
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
void UpdateAI(const uint32 /*diff*/)
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
@@ -191,7 +191,7 @@ enum eScentLarkorwi
|
||||
NPC_LARKORWI_MATE = 9683
|
||||
};
|
||||
|
||||
bool AreaTrigger_at_scent_larkorwi(Player* pPlayer, const AreaTriggerEntry* pAt)
|
||||
bool AreaTrigger_at_scent_larkorwi(Player* pPlayer, const AreaTriggerEntry* /*pAt*/)
|
||||
{
|
||||
if (!pPlayer->isDead() && pPlayer->GetQuestStatus(QUEST_SCENT_OF_LARKORWI) == QUEST_STATUS_INCOMPLETE)
|
||||
{
|
||||
|
||||
@@ -31,8 +31,12 @@ Field::Field(Field &f)
|
||||
|
||||
value = f.GetString();
|
||||
|
||||
if (value && (mValue = new char[strlen(value) + 1]))
|
||||
strcpy(mValue, value);
|
||||
if (value)
|
||||
{
|
||||
mValue = new char[strlen(value) + 1];
|
||||
if (mValue)
|
||||
strcpy(mValue, value);
|
||||
}
|
||||
else
|
||||
mValue = NULL;
|
||||
|
||||
@@ -42,8 +46,12 @@ Field::Field(Field &f)
|
||||
Field::Field(const char *value, enum Field::DataTypes type) :
|
||||
mType(type)
|
||||
{
|
||||
if (value && (mValue = new char[strlen(value) + 1]))
|
||||
strcpy(mValue, value);
|
||||
if (value)
|
||||
{
|
||||
mValue = new char[strlen(value) + 1];
|
||||
if (mValue)
|
||||
strcpy(mValue, value);
|
||||
}
|
||||
else
|
||||
mValue = NULL;
|
||||
}
|
||||
|
||||
+1
-1
@@ -425,7 +425,7 @@ void utf8printf(FILE *out, const char *str, ...)
|
||||
{
|
||||
va_list ap;
|
||||
va_start(ap, str);
|
||||
vutf8printf(stdout, str, &ap);
|
||||
vutf8printf(out, str, &ap);
|
||||
va_end(ap);
|
||||
}
|
||||
|
||||
|
||||
@@ -375,7 +375,7 @@ void CliRunnable::run()
|
||||
WorldDatabase.ThreadStart(); // let thread do safe mySQL requests
|
||||
|
||||
char commandbuf[256];
|
||||
bool canflush = true;
|
||||
|
||||
///- Display the list of available CLI functions then beep
|
||||
sLog.outString("");
|
||||
#if PLATFORM != WINDOWS
|
||||
|
||||
@@ -304,8 +304,6 @@ int Master::Run()
|
||||
uint32 realCurrTime, realPrevTime;
|
||||
realCurrTime = realPrevTime = getMSTime();
|
||||
|
||||
uint32 socketSelecttime = sWorld.getConfig(CONFIG_SOCKET_SELECTTIME);
|
||||
|
||||
///- Start up freeze catcher thread
|
||||
if(uint32 freeze_delay = sConfig.GetIntDefault("MaxCoreStuckTime", 0))
|
||||
{
|
||||
@@ -386,7 +384,7 @@ int Master::Run()
|
||||
b[3].Event.KeyEvent.wVirtualScanCode = 0x1c;
|
||||
b[3].Event.KeyEvent.wRepeatCount = 1;
|
||||
DWORD numb;
|
||||
BOOL ret = WriteConsoleInput(hStdIn, b, 4, &numb);
|
||||
WriteConsoleInput(hStdIn, b, 4, &numb);
|
||||
|
||||
cliThread->wait();
|
||||
|
||||
|
||||
@@ -202,7 +202,7 @@ extern int main(int argc, char **argv)
|
||||
|
||||
///- Launch the listening network socket
|
||||
RealmAcceptor acceptor;
|
||||
|
||||
|
||||
uint16 rmport = sConfig.GetIntDefault("RealmServerPort", DEFAULT_REALMSERVER_PORT);
|
||||
std::string bind_ip = sConfig.GetStringDefault("BindIP", "0.0.0.0");
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@ RealmSocket::RealmSocket(void):
|
||||
|
||||
msg_queue()->high_water_mark(8*1024*1024);
|
||||
msg_queue()->low_water_mark(8*1024*1024);
|
||||
|
||||
|
||||
}
|
||||
|
||||
RealmSocket::~RealmSocket(void)
|
||||
@@ -62,13 +62,13 @@ RealmSocket::~RealmSocket(void)
|
||||
|
||||
if (input_buffer_.length() != 0)
|
||||
input_buffer_.release();
|
||||
|
||||
|
||||
// delete RealmSocketObject must never be called from our code.
|
||||
closing_ = true;
|
||||
|
||||
if (session_)
|
||||
delete session_;
|
||||
|
||||
|
||||
peer().close();
|
||||
}
|
||||
|
||||
@@ -83,7 +83,7 @@ int RealmSocket::open(void * arg)
|
||||
}
|
||||
|
||||
remote_address_ = addr.get_host_addr();
|
||||
|
||||
|
||||
// Register with ACE Reactor
|
||||
if (Base::open(arg) == -1)
|
||||
return -1;
|
||||
@@ -102,7 +102,7 @@ int RealmSocket::open(void * arg)
|
||||
int RealmSocket::close(int)
|
||||
{
|
||||
shutdown();
|
||||
|
||||
|
||||
closing_ = true;
|
||||
|
||||
remove_reference();
|
||||
@@ -267,7 +267,7 @@ int RealmSocket::handle_output(ACE_HANDLE /*= ACE_INVALID_HANDLE*/)
|
||||
ACE_NOTREACHED(return -1);
|
||||
}
|
||||
|
||||
int RealmSocket::handle_close(ACE_HANDLE h, ACE_Reactor_Mask m)
|
||||
int RealmSocket::handle_close(ACE_HANDLE h, ACE_Reactor_Mask /*m*/)
|
||||
{
|
||||
// As opposed to WorldSocket::handle_close, we don't need locks here.
|
||||
|
||||
@@ -275,7 +275,7 @@ int RealmSocket::handle_close(ACE_HANDLE h, ACE_Reactor_Mask m)
|
||||
|
||||
if (h == ACE_INVALID_HANDLE)
|
||||
peer ().close_writer ();
|
||||
|
||||
|
||||
if (session_ != NULL)
|
||||
{
|
||||
session_->OnClose();
|
||||
|
||||
Reference in New Issue
Block a user