diff options
| author | 2015-02-01 15:31:21 -0500 | |
|---|---|---|
| committer | 2015-02-12 09:25:35 -0500 | |
| commit | 8e2b248e05c99c9cf505a351bc9234cedd5fa3b4 (patch) | |
| tree | 05f18714a93d28999c259f4cd86c261deaf659b2 /src/common/string_util.cpp | |
| parent | Merge pull request #384 from neobrain/vertex_shader_debugger (diff) | |
| download | yuzu-8e2b248e05c99c9cf505a351bc9234cedd5fa3b4.tar.gz yuzu-8e2b248e05c99c9cf505a351bc9234cedd5fa3b4.tar.xz yuzu-8e2b248e05c99c9cf505a351bc9234cedd5fa3b4.zip | |
Build: Fixed some warnings
Diffstat (limited to 'src/common/string_util.cpp')
| -rw-r--r-- | src/common/string_util.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/common/string_util.cpp b/src/common/string_util.cpp index b3b772bd9..3264dd51a 100644 --- a/src/common/string_util.cpp +++ b/src/common/string_util.cpp | |||
| @@ -426,7 +426,7 @@ std::u16string UTF8ToUTF16(const std::string& input) | |||
| 426 | 426 | ||
| 427 | static std::string UTF16ToUTF8(const std::wstring& input) | 427 | static std::string UTF16ToUTF8(const std::wstring& input) |
| 428 | { | 428 | { |
| 429 | auto const size = WideCharToMultiByte(CP_UTF8, 0, input.data(), input.size(), nullptr, 0, nullptr, nullptr); | 429 | auto const size = WideCharToMultiByte(CP_UTF8, 0, input.data(), static_cast<int>(input.size()), nullptr, 0, nullptr, nullptr); |
| 430 | 430 | ||
| 431 | std::string output; | 431 | std::string output; |
| 432 | output.resize(size); | 432 | output.resize(size); |
| @@ -439,12 +439,12 @@ static std::string UTF16ToUTF8(const std::wstring& input) | |||
| 439 | 439 | ||
| 440 | static std::wstring CPToUTF16(u32 code_page, const std::string& input) | 440 | static std::wstring CPToUTF16(u32 code_page, const std::string& input) |
| 441 | { | 441 | { |
| 442 | auto const size = MultiByteToWideChar(code_page, 0, input.data(), input.size(), nullptr, 0); | 442 | auto const size = MultiByteToWideChar(code_page, 0, input.data(), static_cast<int>(input.size()), nullptr, 0); |
| 443 | 443 | ||
| 444 | std::wstring output; | 444 | std::wstring output; |
| 445 | output.resize(size); | 445 | output.resize(size); |
| 446 | 446 | ||
| 447 | if (size == 0 || size != MultiByteToWideChar(code_page, 0, input.data(), input.size(), &output[0], output.size())) | 447 | if (size == 0 || size != MultiByteToWideChar(code_page, 0, input.data(), static_cast<int>(input.size()), &output[0], static_cast<int>(output.size()))) |
| 448 | output.clear(); | 448 | output.clear(); |
| 449 | 449 | ||
| 450 | return output; | 450 | return output; |