2
0
Эх сурвалжийг харах

* Patch from Jesus Reyes with better fix for r8726

git-svn-id: trunk@8728 -
joost 18 жил өмнө
parent
commit
fae59501a7

+ 2 - 1
packages/fcl-db/src/fields.inc

@@ -1082,6 +1082,7 @@ begin
   else if FTransliterate then
     begin
     DataSet.Translate(@AValue[1],Buf,True);
+    Buf[DataSize-1] := #0;
     SetData(@buf);
     end
   else
@@ -1090,7 +1091,7 @@ begin
     // the whole buffer-length in SetData. (See bug 8477)
     Buf := AValue;
     // If length(AValue) > Datasize the buffer isn't terminated properly
-    Buf[DataSize] := #0;
+    Buf[DataSize-1] := #0;
     SetData(@Buf);
     end;
 end;