Removed the VReportError() function and moved its functionality into the
[AROS.git] / test / dos / systemtags.c
blob3cb3fef12b4ba263006c434ee86fae2e99d7c665
1 #include <proto/dos.h>
2 #include <proto/alib.h>
4 #include "systemtags.h"
6 #define DEBUG 0
7 #include <aros/debug.h>
9 int main(void)
11 LONG result;
13 /* Execute and wait */
14 result = SystemTags("Echo Synchronous Test", NULL);
15 Printf("Execution results %ld == 0 ?\n", result);
17 /* Start asynchronous */
18 result = SystemTags("Echo Asynchronous Test",
19 SYS_Asynch, TRUE, SYS_Input, SYS_DupStream, SYS_Output, SYS_DupStream,
20 TAG_DONE
22 Printf("Execution results %ld == 0 ?\n", result);
24 /* Start non-existing command asynchronous */
25 result = SystemTags("DoesntExist",
26 SYS_Asynch, TRUE, SYS_Input, SYS_DupStream, SYS_Output, SYS_DupStream,
27 TAG_DONE
29 Printf("Execution results %ld == 0 ?\n", result);
31 /* Test with duplicated Input/Output stream */
32 result = SystemTags("systemtags_slave dont print",
33 SYS_Input, SYS_DupStream, SYS_Output, SYS_DupStream,
34 TAG_DONE
36 Printf("Execution results %ld == 0 ?\n", result);
38 /* Test passing of Input/Output streams */
39 struct STData data;
40 data.input = Input();
41 data.output = Output();
42 D(bug("[systemtags]Input: %p, Output: %p\n", data.input, data.output));
43 UBYTE buf[30];
44 __sprintf(buf, "systemtags_slave %p", &data);
45 result = SystemTags(buf, SYS_Input, BNULL, SYS_Output, BNULL,
46 TAG_DONE
48 Printf("Execution results %ld == 0 ?\n", result);
50 return 0;