浏览代码

* Fix for Mantis #20041, check assignment of buffer in TField.Getdata
(IsNull might call it with a dummy buffer)

git-svn-id: trunk@18854 -

marco 14 年之前
父节点
当前提交
275261f815
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      packages/fcl-db/src/base/fields.inc

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

@@ -558,8 +558,8 @@ begin
     DatabaseErrorFmt(SNoDataset,[FieldName]);
   If FVAlidating then
     begin
-    result:=Not(FValueBuffer=Nil);
-    If Result then
+    result:=assigned(FValueBuffer);
+    If Result and assigned(Buffer) then
       Move (FValueBuffer^,Buffer^ ,DataSize);
     end
   else