Core: Some warning fixes
--HG-- branch : trunk
This commit is contained in:
@@ -238,7 +238,7 @@ bool DisableMgr::IsDisabledFor(DisableType type, uint32 entry, Unit const* pUnit
|
||||
{
|
||||
|
||||
if ((flags & SPELL_DISABLE_PLAYER && pUnit->GetTypeId() == TYPEID_PLAYER) ||
|
||||
(pUnit->GetTypeId() == TYPEID_UNIT && (pUnit->ToCreature()->isPet() && flags & SPELL_DISABLE_PET || flags & SPELL_DISABLE_CREATURE)))
|
||||
(pUnit->GetTypeId() == TYPEID_UNIT && ((pUnit->ToCreature()->isPet() && flags & SPELL_DISABLE_PET) || flags & SPELL_DISABLE_CREATURE)))
|
||||
|
||||
{
|
||||
if (flags & SPELL_DISABLE_MAP)
|
||||
|
||||
@@ -2377,6 +2377,8 @@ void Player::ResetAllPowers()
|
||||
case POWER_RUNIC_POWER:
|
||||
SetPower(POWER_RUNIC_POWER, 0);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5367,8 +5369,6 @@ void Player::HandleBaseModValue(BaseModGroup modGroup, BaseModType modType, floa
|
||||
return;
|
||||
}
|
||||
|
||||
float val = 1.0f;
|
||||
|
||||
switch (modType)
|
||||
{
|
||||
case FLAT_MOD:
|
||||
|
||||
@@ -53,8 +53,9 @@ Loot* Roll::getLoot()
|
||||
return getTarget();
|
||||
}
|
||||
|
||||
Group::Group() : m_leaderGuid(0), m_groupType(GROUPTYPE_NORMAL), m_bgGroup(NULL),
|
||||
m_lootMethod(FREE_FOR_ALL), m_looterGuid(0), m_lootThreshold(ITEM_QUALITY_UNCOMMON),
|
||||
Group::Group() : m_leaderGuid(0), m_leaderName(""), m_groupType(GROUPTYPE_NORMAL),
|
||||
m_dungeonDifficulty(DUNGEON_DIFFICULTY_NORMAL), m_raidDifficulty(RAID_DIFFICULTY_10MAN_NORMAL),
|
||||
m_bgGroup(NULL), m_lootMethod(FREE_FOR_ALL), m_lootThreshold(ITEM_QUALITY_UNCOMMON), m_looterGuid(0),
|
||||
m_subGroupsCounts(NULL), m_guid(0), m_counter(0), m_maxEnchantingLevel(0),
|
||||
m_LfgState(LFG_STATE_NONE), m_LfgOldState(LFG_STATE_NONE), m_LfgDungeonEntry(0), m_Lfgkicks(0)
|
||||
{
|
||||
@@ -2229,4 +2230,4 @@ void Group::ToggleGroupMemberFlag(member_witerator slot, uint8 flag, bool apply)
|
||||
slot->flags |= flag;
|
||||
else
|
||||
slot->flags &= ~flag;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -222,7 +222,7 @@ bool WorldSession::Update(uint32 diff, PacketFilter& updater)
|
||||
|
||||
///- Retrieve packets from the receive queue and call the appropriate handlers
|
||||
/// not process packets if socket already closed
|
||||
WorldPacket* packet;
|
||||
WorldPacket* packet = NULL;
|
||||
while (m_Socket && !m_Socket->IsClosed() && _recvQueue.next(packet, updater))
|
||||
{
|
||||
/*#if 1
|
||||
|
||||
@@ -626,7 +626,7 @@ int WorldSocket::handle_input_missing_data (void)
|
||||
}
|
||||
}
|
||||
|
||||
return n == recv_size ? 1 : 2;
|
||||
return size_t(n) == recv_size ? 1 : 2;
|
||||
}
|
||||
|
||||
int WorldSocket::cancel_wakeup_output (GuardType& g)
|
||||
|
||||
@@ -2375,9 +2375,9 @@ enum eHiddenCultist
|
||||
SAY_HIDDEN_CULTIST_4 = -1571047
|
||||
};
|
||||
|
||||
#define GOSSIP_ITEM_TOM_HEGGER "What do you know about the Cult of the Damned?"
|
||||
#define GOSSIP_ITEM_GUARD_MITCHELLS "How long have you worked for the Cult of the Damned?"
|
||||
#define GOSSIP_ITEM_SALTY_JOHN_THORPE "I have a reason to believe you're involved in the cultist activity"
|
||||
const char* GOSSIP_ITEM_TOM_HEGGER = "What do you know about the Cult of the Damned?";
|
||||
const char* GOSSIP_ITEM_GUARD_MITCHELLS = "How long have you worked for the Cult of the Damned?";
|
||||
const char* GOSSIP_ITEM_SALTY_JOHN_THORPE = "I have a reason to believe you're involved in the cultist activity";
|
||||
|
||||
class npc_hidden_cultist : public CreatureScript
|
||||
{
|
||||
@@ -2515,7 +2515,7 @@ public:
|
||||
bool OnGossipHello(Player* pPlayer, Creature* pCreature)
|
||||
{
|
||||
uint32 uiGossipText = 0;
|
||||
char* charGossipItem = "";
|
||||
const char* charGossipItem;
|
||||
|
||||
switch(pCreature->GetEntry())
|
||||
{
|
||||
@@ -2532,6 +2532,7 @@ public:
|
||||
charGossipItem = GOSSIP_ITEM_GUARD_MITCHELLS;
|
||||
break;
|
||||
default:
|
||||
charGossipItem = "";
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ int RASocket::handle_close(ACE_HANDLE, ACE_Reactor_Mask)
|
||||
|
||||
int RASocket::send(const std::string& line)
|
||||
{
|
||||
return peer().send(line.c_str(), line.length()) == line.length() ? 0 : -1;
|
||||
return size_t(peer().send(line.c_str(), line.length())) == line.length() ? 0 : -1;
|
||||
}
|
||||
|
||||
int RASocket::recv_line(ACE_Message_Block& buffer)
|
||||
@@ -160,7 +160,7 @@ int RASocket::process_command(const std::string& command)
|
||||
break;
|
||||
}
|
||||
|
||||
if (peer().send(mb->rd_ptr(), mb->length()) != mb->length())
|
||||
if (size_t(peer().send(mb->rd_ptr(), mb->length())) != mb->length())
|
||||
{
|
||||
mb->release();
|
||||
return -1;
|
||||
@@ -276,7 +276,7 @@ int RASocket::svc(void)
|
||||
{
|
||||
// show prompt
|
||||
const char* tc_prompt = "TC> ";
|
||||
if (peer().send(tc_prompt, strlen(tc_prompt)) != strlen(tc_prompt))
|
||||
if (size_t(peer().send(tc_prompt, strlen(tc_prompt))) != strlen(tc_prompt))
|
||||
return -1;
|
||||
|
||||
std::string line;
|
||||
|
||||
Reference in New Issue
Block a user