Re: [BUG][FEATURE]

From: George (greerga@DRAGON.HAM.MUOHIO.EDU)
Date: 09/10/97


On Wed, 10 Sep 1997, Sammy wrote:

>It's not that simple.  I allocate 10 buffers at a time.  I can't free any
>of those 10 individually.  I can only free the whole block (unless someone

How about a saving the block number in an integer in the structure and then
running through the list to see if all ten in a block are free?

>knows some malloc/free tricks).  Since I keep a linked list of available
>buffers and used buffers and move buffers between the two very often,
>there's not much chance that given 10 free buffers they will all be in the
>same block of memory.

True.

--
George Greer  -  Me@Null.net   | Genius may have its limitations, but stupidity
http://www.van.ml.org/~greerga | is not thus handicapped. -- Elbert Hubbard


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST