aboutsummaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-support/cpprest/cpprest/950-fix.patch
blob: 3ae46a1159e53c84e83ffd4856469ab7f44bcfee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
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;