Also store the startup information in the arosc libbase and not in
[AROS.git] / test / dos / runcommand.c
blob84251c7d166444e07069cac7eeb35f1347beebe5
1 #include <proto/dos.h>
2 #include <proto/exec.h>
3 #include <dos/bptr.h>
4 #include <dos/dos.h>
5 #include <string.h>
6 #include <stdlib.h>
7 #include <stdio.h>
8 #include "../../rom/exec/etask.h"
10 static LONG get_default_stack_size()
12 struct CommandLineInterface *cli = Cli();
13 return cli->cli_DefaultStack * CLI_DEFAULTSTACK_UNIT;
16 int main(int argc, char **argv)
18 char *fname = "SYS:Utilities/Clock";
19 char *full = "";
20 int lastresult = RETURN_OK;
22 if(fname) {
23 BPTR seglist = LoadSeg(fname);
24 if(seglist)
26 SetProgramName(fname);
27 lastresult=RunCommand(seglist,get_default_stack_size(),
28 full,strlen(full));
29 UnLoadSeg(seglist);
33 exit(0);