mirror of
git://git.openembedded.org/meta-openembedded
synced 2026-01-01 13:58:06 +00:00
Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
27 lines
1.1 KiB
Diff
27 lines
1.1 KiB
Diff
Origin: upstream
|
|
Bug: https://github.com/Microsoft/cpprestsdk/issues/950
|
|
Last-Update: 2018-11-04
|
|
|
|
Index: cpprest/Release/src/utilities/asyncrt_utils.cpp
|
|
===================================================================
|
|
--- cpprest.orig/Release/src/utilities/asyncrt_utils.cpp
|
|
+++ cpprest/Release/src/utilities/asyncrt_utils.cpp
|
|
@@ -356,7 +356,7 @@
|
|
inline size_t count_utf8_to_utf16(const std::string& s)
|
|
{
|
|
const size_t sSize = s.size();
|
|
- auto sData = reinterpret_cast<const UtilCharInternal_t* const>(s.data());
|
|
+ auto const sData = reinterpret_cast<const UtilCharInternal_t*>(s.data());
|
|
size_t result{ sSize };
|
|
|
|
for (size_t index = 0; index < sSize;)
|
|
@@ -441,7 +441,7 @@
|
|
{
|
|
// Save repeated heap allocations, use the length of resulting sequence.
|
|
const size_t srcSize = s.size();
|
|
- auto srcData = reinterpret_cast<const UtilCharInternal_t* const>(s.data());
|
|
+ auto const srcData = reinterpret_cast<const UtilCharInternal_t*>(s.data());
|
|
utf16string dest(count_utf8_to_utf16(s), L'\0');
|
|
utf16string::value_type* const destData = &dest[0];
|
|
size_t destIndex = 0;
|