]> git.xonotic.org Git - xonotic/gmqcc.git/commitdiff
Wrong operand order it's 0xf4u-0xc2u i.e 0x32.
authorDale Weiler <killfieldengine@gmail.com>
Fri, 11 Oct 2013 02:03:13 +0000 (22:03 -0400)
committerDale Weiler <killfieldengine@gmail.com>
Fri, 11 Oct 2013 02:03:13 +0000 (22:03 -0400)
utf8.c

diff --git a/utf8.c b/utf8.c
index 43961576b4f677fa522bdd26917dee2f55696814..6089df19038bfa171b2b1c4352e8f1ee58eb3dff 100644 (file)
--- a/utf8.c
+++ b/utf8.c
@@ -126,7 +126,7 @@ int utf8_to(utf8ch_t *i, const unsigned char *s, size_t n) {
 
     if (*s < 0x80)
         return !!(*i = *s);
-    if (*s-0xC2U > 0xFFFFFFCE)
+    if (*s-0xC2U > 0x32)
         return 0;
 
     c = utf8_tab[*s++-0xC2U];