|
From: Hongli L. <h....@ch...> - 2002-06-19 19:48:49
|
On Wed, 2002-06-19 at 18:47, Mac Reiter wrote: > I'm a little disturbed by the description given below. I'm pretty sure > that argc includes the name of the executable, so that "bot.exe level3.bot" > would have argc == 2. I know that argv[0] contains the name of the > executable, because UN*X systems use this to distinguish behaviors for > symlinked executables (don't ask, it isn't possible on Windows, and it is > slightly odd anyway). The practical upshot is that, for the example above, > argv[0] would be "bot.exe" and argv[1] would be "level3.bot". > Actually, argv[0] is always the full filename of the executable, like C:\Foo\Bar.exe, no matter what you do. In Unix, argv[0] is what you've typed in at the commandline, not the filename of the executable. |