Mail Archives: djgpp/1997/10/12/00:40:59
I tried compiling/running the following program:
/**************** TEST.C *******************/
#include <stdio.h>
int main(int argc, char *argv[])
{
int i;
for (i=0 ; i<argc ; i++) printf("%s ", argv[i]);
printf("\n");
return 0;
}
/************************************************/
Then I tried typing the following command line:
test *.c
And I didn't get the output I expected -- It printed out all of the
files in the directory with the extension ".C". I can see how this can
be useful -- but what if I want to pass "*.c" literally as the first
argument? (which I want to be able to do in a program I wrote). It
seems to me this is impossible to do.
-Chris Frolik
frolikcc AT indy DOT net
- Raw text -