Last change
on this file since 4219 was 4219, checked in by bird, 25 years ago |
Attempt to fix cl.exe compile errors during daily build.
|
File size:
830 bytes
|
Line | |
---|
1 | #define INCL_BASE
|
---|
2 | #include <os2.h>
|
---|
3 | #include <string.h>
|
---|
4 | int main(int argc, char **argv)
|
---|
5 | {
|
---|
6 | static char szArgBuffer[32768];
|
---|
7 | RESULTCODES resc;
|
---|
8 | int argi;
|
---|
9 | char * psz;
|
---|
10 |
|
---|
11 | DosSetMaxFH(100);
|
---|
12 |
|
---|
13 | if (argc < 2)
|
---|
14 | {
|
---|
15 | /* complain */
|
---|
16 | return -1;
|
---|
17 | }
|
---|
18 |
|
---|
19 | /* first argument */
|
---|
20 | psz = strcpy(szArgBuffer, argv[1]);
|
---|
21 | psz += strlen(psz);
|
---|
22 | psz++;
|
---|
23 |
|
---|
24 | if (argc > 2)
|
---|
25 | {
|
---|
26 | argi = 2;
|
---|
27 | while (argi < argc)
|
---|
28 | {
|
---|
29 | strcpy(psz, argv[argi]);
|
---|
30 | psz += strlen(psz);
|
---|
31 | *psz++ = ' ';
|
---|
32 | argi++;
|
---|
33 | }
|
---|
34 | psz[-1] = '\0';
|
---|
35 | }
|
---|
36 | *psz = '\0';
|
---|
37 |
|
---|
38 | if (DosExecPgm(NULL, 0, EXEC_SYNC, szArgBuffer, NULL, &resc, szArgBuffer) != NO_ERROR)
|
---|
39 | {
|
---|
40 | /*complain*/
|
---|
41 | return -1;
|
---|
42 | }
|
---|
43 | return resc.codeResult;
|
---|
44 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.