diff options
| -rw-r--r-- | src/core/hle/service/am/applets/applet_software_keyboard.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/hle/service/am/applets/applet_software_keyboard.cpp b/src/core/hle/service/am/applets/applet_software_keyboard.cpp index 7cae90609..673abb755 100644 --- a/src/core/hle/service/am/applets/applet_software_keyboard.cpp +++ b/src/core/hle/service/am/applets/applet_software_keyboard.cpp | |||
| @@ -377,7 +377,7 @@ void SoftwareKeyboard::SubmitForTextCheck(std::u16string submitted_text) { | |||
| 377 | 377 | ||
| 378 | if (swkbd_config_common.use_utf8) { | 378 | if (swkbd_config_common.use_utf8) { |
| 379 | std::string utf8_submitted_text = Common::UTF16ToUTF8(current_text); | 379 | std::string utf8_submitted_text = Common::UTF16ToUTF8(current_text); |
| 380 | const u64 buffer_size = sizeof(u64) + utf8_submitted_text.size(); | 380 | const u64 buffer_size = utf8_submitted_text.size(); |
| 381 | 381 | ||
| 382 | LOG_DEBUG(Service_AM, "\nBuffer Size: {}\nUTF-8 Submitted Text: {}", buffer_size, | 382 | LOG_DEBUG(Service_AM, "\nBuffer Size: {}\nUTF-8 Submitted Text: {}", buffer_size, |
| 383 | utf8_submitted_text); | 383 | utf8_submitted_text); |
| @@ -386,7 +386,7 @@ void SoftwareKeyboard::SubmitForTextCheck(std::u16string submitted_text) { | |||
| 386 | std::memcpy(out_data.data() + sizeof(u64), utf8_submitted_text.data(), | 386 | std::memcpy(out_data.data() + sizeof(u64), utf8_submitted_text.data(), |
| 387 | utf8_submitted_text.size()); | 387 | utf8_submitted_text.size()); |
| 388 | } else { | 388 | } else { |
| 389 | const u64 buffer_size = sizeof(u64) + current_text.size() * sizeof(char16_t); | 389 | const u64 buffer_size = current_text.size() * sizeof(char16_t); |
| 390 | 390 | ||
| 391 | LOG_DEBUG(Service_AM, "\nBuffer Size: {}\nUTF-16 Submitted Text: {}", buffer_size, | 391 | LOG_DEBUG(Service_AM, "\nBuffer Size: {}\nUTF-16 Submitted Text: {}", buffer_size, |
| 392 | Common::UTF16ToUTF8(current_text)); | 392 | Common::UTF16ToUTF8(current_text)); |