Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2008-03

Little fcl-db patch

2 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Unknown author

Only creates and destroys Constraints, ZEOS depends on it.

Index: packages/fcl-db/src/base/dataset.inc
=================================================================== --- packages/fcl-db/src/base/dataset.inc (revision 10368) +++ packages/fcl-db/src/base/dataset.inc (working copy) @@ -27,6 +27,7 @@

   FFieldDefs:=TFieldDefs.Create(Self);
   FFieldList:=TFields.Create(Self);
   FDataSources:=TList.Create;

+ FConstraints:=TCheckConstraints.Create(Self);

 // FBuffer must be allocated on create, to make Activebuffer return nil
   ReAllocMem(FBuffers,SizeOf(PChar));
@@ -58,6 +59,7 @@
     end;
   for i := 0 to FBufferCount do
     FreeRecordBuffer(FBuffers[i]);
+  FConstraints.Free;
   FreeMem(FBuffers);
   Inherited Destroy;
 end;
Ing. Petr Kristan . EPOS PRO s.r.o., Bozeny Nemcove 2625, 530 02 Pardubice tel: +420 466335223 Czech Republic (Eastern Europe) fax: +420 466510709

Reply by email

Joost van der Sluis
to Unknown author

Thanks, committed r10529.

Joost

Op vrijdag 21-03-2008 om 17:35 uur [tijdzone +0100], schreef

Show quoted text 23 lines
Only creates and destroys Constraints, ZEOS depends on it. Index: packages/fcl-db/src/base/dataset.inc =================================================================== --- packages/fcl-db/src/base/dataset.inc (revision 10368) +++ packages/fcl-db/src/base/dataset.inc (working copy) @@ -27,6 +27,7 @@ FFieldDefs:=TFieldDefs.Create(Self); FFieldList:=TFields.Create(Self); FDataSources:=TList.Create; + FConstraints:=TCheckConstraints.Create(Self); // FBuffer must be allocated on create, to make Activebuffer return nil ReAllocMem(FBuffers,SizeOf(PChar)); @@ -58,6 +59,7 @@ end; for i := 0 to FBufferCount do FreeRecordBuffer(FBuffers[i]); + FConstraints.Free; FreeMem(FBuffers); Inherited Destroy; end;

Reply by email