Skip to content

Commit

Permalink
fix1
Browse files Browse the repository at this point in the history
Signed-off-by: Vladislav Shchapov <[email protected]>
  • Loading branch information
phprus committed Jul 30, 2024
1 parent ff56fce commit 2cd6c57
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion include/fmt/format.h
Original file line number Diff line number Diff line change
Expand Up @@ -1418,10 +1418,12 @@ template <typename WChar, typename Buffer = memory_buffer> class to_utf8 {
if (policy == to_utf8_error_policy::abort) return false;
buf.append(string_view("\xEF\xBF\xBD"));
--p;
continue;
} else {
c = (c << 10) + static_cast<uint32_t>(*p) - 0x35fdc00;
}
} else if (c < 0x80) {
}
if (c < 0x80) {
buf.push_back(static_cast<char>(c));
} else if (c < 0x800) {
buf.push_back(static_cast<char>(0xc0 | (c >> 6)));
Expand Down

0 comments on commit 2cd6c57

Please sign in to comment.