summaryrefslogtreecommitdiffstats
path: root/src/Protocol/ProtocolRecognizer.cpp
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2014-09-29 21:38:11 +0200
committermadmaxoft <github@xoft.cz>2014-09-29 21:38:11 +0200
commitaae90c2cf0d670ab4be05c0e7f09b00523b3b823 (patch)
treef38dfd7b2bc35e92cf789656e717b17213c4afb7 /src/Protocol/ProtocolRecognizer.cpp
parentWorld: Fixed chunk generation by plugins. (diff)
downloadcuberite-aae90c2cf0d670ab4be05c0e7f09b00523b3b823.tar
cuberite-aae90c2cf0d670ab4be05c0e7f09b00523b3b823.tar.gz
cuberite-aae90c2cf0d670ab4be05c0e7f09b00523b3b823.tar.bz2
cuberite-aae90c2cf0d670ab4be05c0e7f09b00523b3b823.tar.lz
cuberite-aae90c2cf0d670ab4be05c0e7f09b00523b3b823.tar.xz
cuberite-aae90c2cf0d670ab4be05c0e7f09b00523b3b823.tar.zst
cuberite-aae90c2cf0d670ab4be05c0e7f09b00523b3b823.zip
Diffstat (limited to 'src/Protocol/ProtocolRecognizer.cpp')
-rw-r--r--src/Protocol/ProtocolRecognizer.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Protocol/ProtocolRecognizer.cpp b/src/Protocol/ProtocolRecognizer.cpp
index ef6802d2b..4f8eb59db 100644
--- a/src/Protocol/ProtocolRecognizer.cpp
+++ b/src/Protocol/ProtocolRecognizer.cpp
@@ -201,9 +201,9 @@ void cProtocolRecognizer::SendDisconnect(const AString & a_Reason)
SendData((const char *)&Packet, 1); // WriteByte()
AString UTF16 = UTF8ToRawBEUTF16(a_Reason.c_str(), a_Reason.length());
- static const short Size = htons((short)(UTF16.size() / 2));
- SendData((const char *)&Size, 2); // WriteShort()
- SendData(UTF16.data(), UTF16.size()); // WriteString()
+ static const u_short Size = htons((u_short)(UTF16.size() / 2));
+ SendData((const char *)&Size, 2); // WriteShort()
+ SendData(UTF16.data(), UTF16.size()); // WriteString()
}
}