2 Copyright © 1995-2007, The AROS Development Team. All rights reserved.
9 #include <proto/exec.h>
10 #include <proto/locale.h>
11 #include "asl_intern.h"
13 /*****************************************************************************
16 #include <proto/asl.h>
18 AROS_LH1(void, FreeAslRequest
,
21 AROS_LHA(APTR
, requester
, A0
),
24 struct Library
*, AslBase
, 9, Asl
)
27 Frees a requester that was allocated with AllocAslRequest().
30 requester - The requester that is to be freed.
45 27-11-96 digulla automatically created from
46 asl_lib.fd and clib/asl_protos.h
48 *****************************************************************************/
52 /* Here We should also free WBArg when multiselection etc. etc. */
53 struct ReqNode
*reqnode
;
55 if (!requester
) return;
57 if ((reqnode
= FindReqNode(requester
, ASLB(AslBase
))) != NULL
)
59 /* Strip requester specific stuff */
60 StripRequester(requester
, reqnode
->rn_IntReq
->ir_ReqType
, ASLB(AslBase
));
63 DeletePool(reqnode
->rn_IntReq
->ir_MemPool
);
64 FreeVec(reqnode
->rn_IntReq
);
66 ObtainSemaphore( &(ASLB(AslBase
)->ReqListSem
) );
67 Remove( (struct Node
*)reqnode
);
68 ReleaseSemaphore( &(ASLB(AslBase
)->ReqListSem
) );
70 FreeMem(reqnode
, sizeof (struct ReqNode
));
77 } /* FreeAslRequest */