A buffer variable wasn't dereferenced in two similar comparisons in ResList
[AROS.git] / compiler / alib / createtask.c
blob8630b2c95bb1a47945ab60fcdd68aaeccaae6cc5
1 /*
2 Copyright © 1995-2011, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Create a new Amiga task
6 Lang: english
7 */
9 #include <exec/memory.h>
10 #include <exec/execbase.h>
11 #include <proto/exec.h>
13 /*****************************************************************************
15 NAME */
16 #include <exec/tasks.h>
17 #include <proto/alib.h>
19 struct Task * CreateTask (
21 /* SYNOPSIS */
22 STRPTR name,
23 LONG pri,
24 APTR initpc,
25 ULONG stacksize)
27 /* FUNCTION
28 Create a new task.
30 INPUTS
31 name - Name of the task. The string is not copied. Note that
32 task names' need not be unique.
33 pri - The initial priority of the task (normally 0)
34 initpc - The address of the first instruction of the
35 task. In most cases, this is the address of a
36 function.
37 stacksize - The size of the stack for the task. Always
38 keep in mind that the size of the stack must include
39 the amount of stack which is needed by the routines
40 called by the task.
42 RESULT
43 A pointer to the new task or NULL on failure.
45 NOTES
47 EXAMPLE
49 BUGS
51 SEE ALSO
53 INTERNALS
55 HISTORY
57 ******************************************************************************/
59 return NewCreateTask(TASKTAG_NAME, name,
60 TASKTAG_PRI, pri,
61 TASKTAG_PC, initpc,
62 TASKTAG_STACKSIZE, stacksize,
63 TAG_END);
64 } /* CreateTask */