argv[0] in execvp()
From: Alex Vinokur (alexvn_at_users.sourceforge.net)
Date: 11/26/05
- Next message: Bjørn Augestad: "Re: strange problem with MySQL"
- Previous message: Brian C: "Re: String Pointer to Functions"
- Next in thread: Paul Pluzhnikov: "Re: argv[0] in execvp()"
- Reply: Paul Pluzhnikov: "Re: argv[0] in execvp()"
- Reply: Lew Pitcher: "Re: argv[0] in execvp()"
- Reply: Gordon Burditt: "Re: argv[0] in execvp()"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 25 Nov 2005 21:30:18 -0800
QUOTES from http://www.mkssoftware.com/docs/man3/execl.3.asp
----------------------------------------------------
int execvp(const char *file, char *const argv[])
argv
Is the argument list for the new process image. This should contain an
array of pointers to character strings, and the array should be
terminated by a NULL pointer. The value in argv[0] should point to a
file name that is associated with the process being started by the
exec() function.
-----------------------------------------------------
Why should 'argv[0]' point to a file name?
Is not it enough the 'file' parameter to execute the program?
Alex Vinokur
email: alex DOT vinokur AT gmail DOT com
http://mathforum.org/library/view/10978.html
http://sourceforge.net/users/alexvn
- Next message: Bjørn Augestad: "Re: strange problem with MySQL"
- Previous message: Brian C: "Re: String Pointer to Functions"
- Next in thread: Paul Pluzhnikov: "Re: argv[0] in execvp()"
- Reply: Paul Pluzhnikov: "Re: argv[0] in execvp()"
- Reply: Lew Pitcher: "Re: argv[0] in execvp()"
- Reply: Gordon Burditt: "Re: argv[0] in execvp()"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|