Ver código fonte

* Avoid range-check error

git-svn-id: trunk@10236 -
joost 17 anos atrás
pai
commit
16ff4076ee
1 arquivos alterados com 2 adições e 1 exclusões
  1. 2 1
      packages/fcl-db/src/base/dsparams.inc

+ 2 - 1
packages/fcl-db/src/base/dsparams.inc

@@ -402,7 +402,8 @@ begin
       BufIndex:=ParamPart[i].Stop;
     end;
     CopyLen:=Length(SQL)+1-BufIndex;
-    Move(SQL[BufIndex],NewQuery[NewQueryIndex],CopyLen);
+    if CopyLen > 0 then
+      Move(SQL[BufIndex],NewQuery[NewQueryIndex],CopyLen);
   end
   else
     NewQuery:=SQL;