httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sameer <sam...@c2.net>
Subject Re: The majic number is 8192 bytes. Clear_pool, destroy_pool fail is pool has 8192 bytes. (fwd)
Date Thu, 16 Jan 1997 22:07:16 GMT
	Forwarded email about leaks in alloc.c from my guy looking at
this. Anyone have any thoughts? I'm going to look into this in more
detail.

> > Sameer
> >
> > The majic number is 8192.
> >
> > My leak is in the alloc.c
> > If the pool has 8192 bytes,
> > the clear_pool and destroy_pool will fail.
> >
> > Try this ANYWHERE at all:
> >
> > Pool *pLocalPool = make_sub_pool ( USE ANY POOL  );
> > Char *pszText = palloc ( pLocalPool, 8192 );
> >
> > int cbInLocalPool = bytes_in_pool ( pLocalPool ); // returns 8192
> > int cbInFreeBlocks = bytes_in_free_blocks();    // returns for example X
> >
> > clear_pool ( pLocalPool );
> >
> > cbInLocalPool   = bytes_in_pool ( pLocalPool );   // returns 8192 !!!!!
> > cbInFreeBlocks  = bytes_in_free_blocks();         // returns X + 8192
> >
> > destroy_pool ( pLocalPool );
> > cbInLocalPool   = bytes_in_pool ( pLocalPool );         // returns 8192
> > cbInFreeBlocks  = bytes_in_free_blocks();       // returns X + 8192

-- 
Sameer Parekh					Voice:   510-986-8770
President					FAX:     510-986-8777
C2Net 		    C2Net is having a party: http://www.c2.net/party/
http://www.c2.net/				sameer@c2.net

Mime
View raw message