summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/beinghandler.cpp5
-rw-r--r--src/net/eathena/messageout.cpp3
2 files changed, 5 insertions, 3 deletions
diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp
index a11f3bae8..e21a1d0e6 100644
--- a/src/net/eathena/beinghandler.cpp
+++ b/src/net/eathena/beinghandler.cpp
@@ -434,7 +434,7 @@ void BeingHandler::processPlayerMoveUpdate(Net::MessageIn &msg,
const uint16_t stunMode = msg.readInt16(); // opt1
uint32_t statusEffects = msg.readInt16(); // opt2
statusEffects |= (static_cast<uint16_t>(msg.readInt16()))
- << 16; // status.options; Aethyra uses this as misc2
+ << 16U; // status.options; Aethyra uses this as misc2
const int16_t job = msg.readInt16();
int disguiseId = 0;
if (id < 110000000 && job >= 1000)
@@ -648,7 +648,8 @@ void BeingHandler::processBeingVisibleOrMove(Net::MessageIn &msg,
int16_t speed = msg.readInt16();
const uint16_t stunMode = msg.readInt16(); // opt1
uint32_t statusEffects = msg.readInt16(); // opt2
- statusEffects |= (static_cast<uint16_t>(msg.readInt16())) << 16; // option
+ statusEffects |= (static_cast<uint16_t>(
+ msg.readInt16())) << 16U; // option
const int16_t job = msg.readInt16(); // class
Being *dstBeing = actorManager->findBeing(id);
diff --git a/src/net/eathena/messageout.cpp b/src/net/eathena/messageout.cpp
index 49b67b84e..386f5b046 100644
--- a/src/net/eathena/messageout.cpp
+++ b/src/net/eathena/messageout.cpp
@@ -95,7 +95,8 @@ void MessageOut::writeCoordinates(const uint16_t x,
static_cast<unsigned>(x),
static_cast<unsigned>(y),
static_cast<unsigned>(direction)));
- char *const data = mData + mPos;
+ unsigned char *const data = reinterpret_cast<unsigned char*>(mData)
+ + static_cast<size_t>(mPos);
mNetwork->mOutSize += 3;
mPos += 3;