Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/doitsujin/dxvk.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoshua Ashton <joshua@froggi.es>2023-06-10 14:21:41 +0300
committerJoshua Ashton <joshua@froggi.es>2023-06-10 14:21:41 +0300
commit8fd110e9fbdb85e2c8caae0a07d9f8de716a136c (patch)
tree51bdd89b63e18d6b09182939c29becca95e8d2c6
parentf3fb5ba320c2e312e2b026acd82280f70d9213c3 (diff)
[util] Fix UTF8 encodeTypedChar for 4 byte charsemoji_encode_fix
Some flipped logic here...
-rw-r--r--src/util/util_string.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util/util_string.cpp b/src/util/util_string.cpp
index 8a7a2248..b555a881 100644
--- a/src/util/util_string.cpp
+++ b/src/util/util_string.cpp
@@ -126,7 +126,7 @@ namespace dxvk::str {
return 3;
} else if (ch < 0x200000) {
if (begin) {
- if (unlikely(begin + 4 < end))
+ if (unlikely(begin + 4 > end))
return 0;
begin[0] = uint8_t(0xF0 | ((ch >> 18)));