Trust uboot's device list only if it does not look suspicious.
[AROS.git] / test / kernel / stackcheck.c
blobce55cf09fad67fb12dd3672a414ce48660cc292b
1 #include <exec/tasks.h>
2 #include <proto/dos.h>
3 #include <proto/exec.h>
5 #include <stdio.h>
7 int __nocommandline = 1;
9 int main(void)
11 int i;
12 struct Task *t = FindTask(NULL);
14 printf("Attempting weird suicide...\n");
16 /* Simulate runaway stack */
17 t->tc_SPLower = (APTR)10;
18 t->tc_SPUpper = (APTR)16;
20 for (i = 1; i < 6; i++)
22 printf("%d...\n", i);
23 /* Delay() should eventually end up in core_Dispatch() which should kill us */
24 Delay(50);
27 printf("Stack checking FAILED! GO FIX IT!\n");
28 return 0;