[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: possible memory leaks, FreeBSD,mod_perl/1.29


On Fri, 2006-09-29 at 19:31 +0300, Assen Tchorbadjiev wrote:
> This is the dummy handler package
> ====================
> package My::X;
> sub handler {
> 	my $r = shift;
> 	$r->content_type( 'text/html' );
> 	$r->send_http_header();
> 	$r->print( $$ );
> 	200;
> }
> 1;

That's all you have loaded?

This code does have a bug, which is the 200 at the end.  You should
return OK from Apache::Const instead.  These are not HTTP response
codes.

I don't use FreeBSD, but I would second Jonathan's advice about
measuring size every 100-1000 requests rather than every request.  It
can take a while to hit equilibrium because of the way perl allocates
memory.

- Perrin


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.