libpq++ memory problems
| От | Tim Brookes |
|---|---|
| Тема | libpq++ memory problems |
| Дата | |
| Msg-id | 38FB6FA1.C63B030B@mcmail.com обсуждение исходный текст |
| Ответы |
Re: libpq++ memory problems
|
| Список | pgsql-interfaces |
I have written the following small piece of code to illustrate my
problem.
#include <pgsql/libpq++.h>
void callproc(){ PgDatabase* loStatsdb; PgEnv loEnv("","","","","");
loStatsdb = new PgDatabase(loEnv,"ftldb"); delete loStatsdb;
};
main(){ while(1){ callproc(); };
};
The procedure 'callproc' is called in a continuous loop to emphasise
this problem. Within the procedure all that happens is a new database
connection is made and deleted. On my system this eats memory at an
enormous rate.
I do not know if this problem has been discussed before or fixed in
newer versions of the library (my apologies if it has), but I would be
most grateful of any info on resolving this memory leak.
Tim Brookes
В списке pgsql-interfaces по дате отправления: