2 Copyright © 1995-2002, The AROS Development Team. All rights reserved.
6 #include <proto/exec.h>
7 #include <aros/libcall.h>
8 #include <clib/exec_protos.h>
9 #include <exec/execbase.h>
14 /* Function prototype needed on Linux-M68K*/
15 AROS_LD2(ULONG
,handler
,
16 AROS_LDA(ULONG
,signals
,D0
),
17 AROS_LDA(APTR
,exceptData
,A1
),
18 struct ExecBase
*,SysBase
,0,Test
);
20 AROS_LH2(ULONG
,handler
,
21 AROS_LHA(ULONG
,signals
,D0
),
22 AROS_LHA(APTR
,exceptData
,A1
),
23 struct ExecBase
*,SysBase
,0,Test
)
40 printf("sig1: %d\n",s1
);
44 printf("sig2: %d\n",s2
);
45 oldexc
=SysBase
->ThisTask
->tc_ExceptCode
;
46 SysBase
->ThisTask
->tc_ExceptCode
=&AROS_SLIB_ENTRY(handler
,Test
,0);
47 SetExcept(1<<s2
,1<<s2
);
48 Signal(SysBase
->ThisTask
,(1<<s2
)|(1<<s1
));
50 SysBase
->ThisTask
->tc_ExceptCode
=oldexc
;
51 printf("got: %08lx\n",(unsigned long)s
);