mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-15 23:20:36 +01:00
Core/Channel: Fix CRT Debug Assert triggered with invalid channel names
This commit is contained in:
@@ -49,7 +49,7 @@ void WorldSession::HandleJoinChannel(WorldPacket& recvPacket)
|
||||
return;
|
||||
}
|
||||
|
||||
if (channelName.empty() || isdigit(channelName[0]))
|
||||
if (channelName.empty() || isdigit((unsigned char)channelName[0]))
|
||||
{
|
||||
WorldPacket data(SMSG_CHANNEL_NOTIFY, 1 + channelName.size());
|
||||
data << uint8(CHAT_INVALID_NAME_NOTICE) << channelName;
|
||||
|
||||
@@ -728,7 +728,7 @@ public:
|
||||
return false;
|
||||
|
||||
amount = atoi(rankTxt);
|
||||
if ((amount == 0) && (rankTxt[0] != '-') && !isdigit(rankTxt[0]))
|
||||
if ((amount == 0) && (rankTxt[0] != '-') && !isdigit((unsigned char)rankTxt[0]))
|
||||
{
|
||||
std::string rankStr = rankTxt;
|
||||
std::wstring wrankStr;
|
||||
|
||||
Reference in New Issue
Block a user