On Tue, Aug 13, 2002 at 01:57:54PM +0200, MyBox wrote:
>
> function testfunc($var1,$var2)
> {
> ...many calculation and variables
> return $result;
> }
>
> then on call number 12 the script exits whith error-message:
> Fatal error: Allowed memory size of 8388608 bytes exhausted
Exhausting 8 megs of RAM! WOW! Those are some serious calculations!
> Must i giving free the memory at hand?
Yes.
> When i in the function before its end give all vars free with unset(); then
> the error also comes on the same place.
Hmm... Where are you performing the unset()'s? Before the return, right?
Perhaps the memory is being gobbled up by the return $result?
I did a search on the mailing list archive trying to learn more about
this, but didn't come up with much. Hopefully, someone with more
knowledge on PHP's internals will comment.
--Dan
--
PHP classes that make web design easier
SQL Solution | Layout Solution | Form Solution
sqlsolution.info | layoutsolution.info | formsolution.info
T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y
4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php