mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
String: Use string length during UTF8 conversion
This implementation is equivalent to JUCE 7.
This commit is contained in:
parent
4828bd886d
commit
131b838c65
1 changed files with 1 additions and 1 deletions
|
|
@ -2164,7 +2164,7 @@ String String::fromUTF8 (const char* const buffer, int bufferSizeBytes)
|
|||
}
|
||||
|
||||
jassert (CharPointer_UTF8::isValidString (buffer, bufferSizeBytes));
|
||||
return { CharPointer_UTF8 (buffer), (size_t) bufferSizeBytes };
|
||||
return { CharPointer_UTF8 (buffer), CharPointer_UTF8 (buffer + bufferSizeBytes) };
|
||||
}
|
||||
|
||||
#if __cpp_char8_t
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue