char argvv[8][32];
int func(int n, ...)
{
va_list vl;
va_start(vl, 8);
if (i = 1; i <= n; i++)
{
strcpy(argvv[i], va_arg(vl, char *));
}
va_end(vl);
parseArgs(n, argvv);
...
}
在另一个文件中,我定义:
void parseArgs(int argc, char **argv)
{
printf("arg1:%s\n", argv[1]);
/* ????? I know this is not right; how to access the second argument */
}