This is the mail archive of the
cygwin
mailing list for the Cygwin project.
commanline argument parsing
- From: grischka <gr1008 at googlemail dot com>
- To: cygwin at cygwin dot com
- Date: Tue, 30 Jun 2009 23:11:04 +0200
- Subject: commanline argument parsing
If I compile this snippet:
#include <stdio.h>
int main (int argc, char **argv)
{
int i;
for (i = 0; i < argc; ++i)
printf("argv[%d] %s\n", i, argv[i]);
return 0;
}
with cygwin GCC and then run it from CMD prompt:
C:\cygwin\home\me> test \"stuff\"
it prints this:
argv[0] test
argv[1] \stuff"
Is that expected? I'm aware that there is some conversion going on
and that it's meant to work from a cygwin shell really, but still.
Could someone shed light upon the reasoning with this?
--- gr
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple