Memory Free

This function frees memory allocated by the previous program. To reiterate, memory is allocated out of a block of memory, in multiples of a specified block size. A consecutive group of blocks of memory, whether free or allocated, is called a span. An “in use” array tracks whether each block is allocated or freed. If a span is free, all the entries in the “in use” array that correspond to the blocks in the span contain the same positive value, which is the number of blocks in the span. If a span is allocated, all the corresponding entries in the “in use” array contain the same negative value, which is the negative of the number of blocks ...

Get Find the Bug A Book of Incorrect Programs now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.