"Jukka Zitting" <
jukka.zitting@gmai...> wrote:
>
> Can you make a bug report with example code and the valgrind report? I
> can take a look at that.
No I can not, but:
<?php
for ($i = 0 ; $i > 500; $i++) {
$qb = new midgardquerybuilder("classname");
$qb->add_constraint("id", "=", 1);
$qb->execute();
}
?>
VS:
<?php
for ($i = 0 ; $i > 500; $i++) {
$object = new midgard_classname();
$object->get_by_id(1);
}
Both codes uses the same core's functionality , both uses zend's hash API.
The first one produces memleak which is proportional to $i.
I do not have php compiled from sources here , so all I ( and valgrind ) can say is '??????'
> The Zend resource handler is used extensively by things like the PHP
> mysql extension, and I've seen no memory problems even though I've
> used that quite a lot.
I doubt you have more than 10 mysql's connection handlers ( with resource handler )
available during request. And I am sure that there are much more than 10 resource handlers
for QB during request.
Piotras
---------------------------------------------------------------------
To unsubscribe, e-mail:
dev-unsubscribe@midg...
For additional commands, e-mail:
dev-help@midg...
opensubscriber is not affiliated with the authors of this message nor responsible for its content.