浏览代码

* Exit find if not sorted (bug id 28774)

git-svn-id: trunk@31941 -
michael 9 年之前
父节点
当前提交
aa3a7b7eb8
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      rtl/objpas/classes/stringl.inc

+ 2 - 0
rtl/objpas/classes/stringl.inc

@@ -1390,6 +1390,8 @@ var
   CompareRes: PtrInt;
 begin
   Result := false;
+  if Not Sorted then 
+    exit;
   // Use binary search.
   L := 0;
   R := Count - 1;