瀏覽代碼

fixing out of bounds

byte 6 月之前
父節點
當前提交
456a70a7ba
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      xs_unicode.h

+ 1 - 1
xs_unicode.h

@@ -232,7 +232,7 @@ unsigned int *_xs_unicode_upper_search(unsigned int cpoint)
 /* searches for an uppercase codepoint in the case fold table */
 {
     int b = 0;
-    int t = xs_countof(xs_unicode_case_fold_table) / 2 + 1;
+    int t = xs_countof(xs_unicode_case_fold_table) / 2 - 1;
 
     while (t >= b) {
         int n = (b + t) / 2;