mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-15 00:24:19 +00:00
String::charToString fix.
This commit is contained in:
parent
8df744472d
commit
3957158ec9
2 changed files with 2 additions and 2 deletions
|
|
@ -11784,7 +11784,7 @@ String::String (const CharPointer_UTF32& start, const CharPointer_UTF32& end) :
|
|||
|
||||
const String String::charToString (const juce_wchar character)
|
||||
{
|
||||
String result (PreallocationBytes (sizeof (CharPointerType::CharType)));
|
||||
String result (PreallocationBytes (CharPointerType::getBytesRequiredFor (character)));
|
||||
CharPointerType t (result.text);
|
||||
t.write (character);
|
||||
t.writeNull();
|
||||
|
|
|
|||
|
|
@ -318,7 +318,7 @@ String::String (const CharPointer_UTF32& start, const CharPointer_UTF32& end) :
|
|||
|
||||
const String String::charToString (const juce_wchar character)
|
||||
{
|
||||
String result (PreallocationBytes (sizeof (CharPointerType::CharType)));
|
||||
String result (PreallocationBytes (CharPointerType::getBytesRequiredFor (character)));
|
||||
CharPointerType t (result.text);
|
||||
t.write (character);
|
||||
t.writeNull();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue