Fix #6390: Crash when renaming rides in multiplayer

This commit is contained in:
Mark van Renswoude authored and Michael Steenbeek committed 2017-10-14 14:21:06 +02:00
1 parent 167662f651
commit ce73d3a8a5
2 files changed
+3 -3

No files matched your search

+2 -2
View File
@@ -65,8 +65,8 @@ struct DataSerializerTraits<std::string>
static void encode(IStream *stream, const std::string& str)
{
uint16 len = (uint16)str.size();
len = ByteSwapBE(len);
stream->Write(&len);
uint16 swapped = ByteSwapBE(len);
stream->Write(&swapped);
stream->WriteArray(str.c_str(), len);
}
static void decode(IStream *stream, std::string& res)
+1 -1
View File
@@ -51,7 +51,7 @@ typedef struct GameAction GameAction;
// This define specifies which version of network stream current build uses.
// It is used for making sure only compatible builds get connected, even within
// single OpenRCT2 version.
#define NETWORK_STREAM_VERSION "14"
#define NETWORK_STREAM_VERSION "15"
#define NETWORK_STREAM_ID OPENRCT2_VERSION "-" NETWORK_STREAM_VERSION
#ifdef __cplusplus