1DELPTYPE(3)                  MBK UTILITY FUNCTIONS                 DELPTYPE(3)
2
3
4

NAME

6       delptype - delete an element of a ptype_list
7

SYNOPSIS

9       #include "mut.h"
10       ptype_list ∗delptype(pthead, type)
11       ptype_list ∗pthead;
12       long type;
13

PARAMETERS

15       pthead              Pointer to a ptype list
16
17       type                The pointer of this type is to be deleted.
18

DESCRIPTION

20       delptype  deletes  the element of the ptype_list that has the type type
21       in the list pointed to by pthead.  The list consistency is  maintained,
22       and the element put back in the list of free blocks.
23

RETURN VALUE

25       delptype  returns  a pointer to the new head of list if a typed pointer
26       used to belong to the list. In most case, it has the value  of  pthead.
27       If the type doesn't belong to the list, NULL is returned.
28

ERROR

30       "∗∗∗ mbk error ∗∗∗ delptype impossible : pthead = NULL"
31              The  pointer  to  the  head of list is NULL, and that clear that
32              such a list can't be ran thru.
33

EXAMPLE

35       #include "mut.h"
36       #include "mph.h"
37       void delete_user(ptfig)
38       phfig_list ∗ptfig;
39       {
40       phins_list ∗i;
41          for (i = ptfig->PHINS; i; i = i->NEXT)
42             i->USER = delptype(i->USER, PLACEABOX);
43       }
44

SEE ALSO

46       mbk(1), ptype(3), addptype(3), getptype(3), freeptype(3).
47
48
49
50
51
52
53ASIM/LIP6                       October 1, 1997                    DELPTYPE(3)
Impressum