Page 1 of 1

memory leak - firebird

Posted: 15.09.2006, 11:34
by barko
hi

I have tested some things with this code:

Code: Select all

var i:integer;
begin
  for i:=1 to 1500 do
  begin
    ZQuery.Close;
    ZQuery.SQL.text:='select * from anytable;';
    ZQuery.Open;
  end;
end;
And with KDE memory info software I got results; memory is filled up but is not released (on ZQuery.Close) until I close program... is there any way to confirm this?

This is on linux, lazarus (latest from svn),fpc (latest from svn), firebird database 1.5 and zeosdbo from svn (latest)...

my english sux...i know... ;)

Posted: 17.09.2006, 22:10
by barko
I made same test with SQLdb (included in lazarus) and RAM (memory) is not filled up (it's released after query.close)... so, in zeosdbo is memory leak (may be somewhere in interbase/firebird units?)...

Posted: 18.09.2006, 08:09
by mdaems
Hi Barko,

I've found 1 past reference to memory leaks in Firebird units and that one is Here.
It should be fixed in testing branch, but the original poster never confirmed it worked. Unfortunately I never used firebird and have no experience with memory leaks. If you can find them, please go on. If not please confirm you are using a version where the change from the link above has been done, so the other know that's NOT the problem.

Mark

Posted: 18.09.2006, 11:09
by barko
I use latest version from SVN (testing branch), so I think this fix is included... and memory leak is still present...

Posted: 08.11.2006, 23:25
by barko
Hi!

I want to thank jacques.bernardes for his work on memory leak of zeosdbo. With svn rev. 169 (testing branch) is this memory leak gone!

:D

Posted: 09.11.2006, 13:04
by gto
I want to thank jacques.bernardes for his work on memory leak of zeosdbo.
Am I missing something? :D

@mdaems: I'm the original poster for the topic you cited, and yes, it works :)

Posted: 09.11.2006, 13:24
by mdaems
@gto:
Maybe jou just missed the fact that my post is quite 'old'.

At that moment jaques did not yet find the recently fixed bug. (See bug reports section). It's that fix barko is refering to. You first fix was not bad, but jacques has found another leak.

Mark

Posted: 09.11.2006, 14:23
by gto
Ohh right. Didn't see the date :mrgreen:
sorry!