tools/adflib: build only host variant which is used by Sam440 target
[AROS.git] / rom / exec / freesignal.c
blobf504829769d517d1dedec06d6d7dedf2557a1908
1 /*
2 Copyright © 1995-2009, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Free a signal.
6 Lang: english
7 */
8 #include <exec/execbase.h>
9 #include <exec/tasks.h>
10 #include <aros/libcall.h>
11 #include <proto/exec.h>
13 #include "exec_intern.h"
15 /*****************************************************************************
17 NAME */
19 AROS_LH1(void, FreeSignal,
21 /* SYNOPSIS */
22 AROS_LHA(LONG, signalNum, D0),
24 /* LOCATION */
25 struct ExecBase *, SysBase, 56, Exec)
27 /* FUNCTION
28 Free a signal allocated with AllocSignal().
30 INPUTS
31 signalNum - Number of the signal to free or -1 to do nothing.
33 RESULT
35 NOTES
37 EXAMPLE
39 BUGS
41 SEE ALSO
42 AllocSignal(), Signal(), Wait()
44 INTERNALS
46 ******************************************************************************/
48 AROS_LIBFUNC_INIT
50 if(signalNum!=-1)
52 /* No more atomic problem - i beleive THIS is atomic. - sonic */
53 struct Task *me = GET_THIS_TASK;
55 /* Clear the bit */
56 me->tc_SigAlloc &= ~(1<<signalNum);
58 AROS_LIBFUNC_EXIT
59 } /* FreeSignal() */