瀏覽代碼

ImStrnicmp tweak

ocornut 10 年之前
父節點
當前提交
38164a410d
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      imgui.cpp

+ 1 - 1
imgui.cpp

@@ -442,7 +442,7 @@ static int ImStrnicmp(const char* str1, const char* str2, int count)
 {
     int d = 0;
     while (count > 0 && (d = toupper(*str2) - toupper(*str1)) == 0 && *str1) { str1++; str2++; count--; }
-    return (count == 0) ? 0 : d;
+    return d;
 }
 
 static char* ImStrdup(const char *str)