1FREECHAIN(3) MBK UTILITY FUNCTIONS FREECHAIN(3)
2
3
4
6 freechain - free a chain_list
7
9 #include "mut.h"
10 void freechain(pt)
11 chain_list ∗pt;
12
14 pt Pointer to the chain list to be freed
15
17 freechain frees the chain_list pointed to by pt. All the elements of
18 the list are put back in the list of free blocks.
19
21 #include "mut.h"
22 void free_from(c, i) /∗ erase list from ith element ∗/
23 chain_list ∗c;
24 int i;
25 {
26 chain_list ∗t;
27 while (i--)
28 c = c->NEXT;
29 t = c->NEXT, c->NEXT = NULL;
30 freechain(t);
31 }
32
34 mbk(1), chain(3), addchain(3), delchain(3).
35
36
37
38
39
40
41ASIM/LIP6 October 1, 1997 FREECHAIN(3)