diff options
author | glx22 <glx22@users.noreply.github.com> | 2019-03-28 00:09:33 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-28 00:09:33 +0100 |
commit | 66dd7c3879123bb99b712375b66b577f81d53a96 (patch) | |
tree | 6231635658dab5ba63b776e9350884c083617cb1 /src/strgen | |
parent | e817951bfdc229b404d5fec188c67f5202a0e774 (diff) | |
download | openttd-66dd7c3879123bb99b712375b66b577f81d53a96.tar.xz |
Fix: MSVC warnings (#7423)
Diffstat (limited to 'src/strgen')
-rw-r--r-- | src/strgen/strgen_base.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/strgen/strgen_base.cpp b/src/strgen/strgen_base.cpp index f0dc03aa0..00c3fb9f6 100644 --- a/src/strgen/strgen_base.cpp +++ b/src/strgen/strgen_base.cpp @@ -1029,14 +1029,14 @@ void LanguageWriter::WriteLang(const StringData &data) for (c = casep; c != NULL; c = c->next) { buffer.AppendByte(c->caseidx); /* Make some space for the 16-bit length */ - uint pos = buffer.size(); + uint pos = (uint)buffer.size(); buffer.AppendByte(0); buffer.AppendByte(0); /* Write string */ PutCommandString(&buffer, c->string); buffer.AppendByte(0); // terminate with a zero /* Fill in the length */ - uint size = buffer.size() - (pos + 2); + uint size = (uint)buffer.size() - (pos + 2); buffer[pos + 0] = GB(size, 8, 8); buffer[pos + 1] = GB(size, 0, 8); } @@ -1044,7 +1044,7 @@ void LanguageWriter::WriteLang(const StringData &data) if (cmdp != NULL) PutCommandString(&buffer, cmdp); - this->WriteLength(buffer.size()); + this->WriteLength((uint)buffer.size()); this->Write(buffer.data(), buffer.size()); buffer.clear(); } |