|
MentOS
0.8.0
The Mentoring Operating System
|
Macros | |
| #define | DEFAULT_PATH "/bin:/usr/bin" |
Default PATH. | |
Functions | |
| static int | __find_in_path (const char *file, char *buf, size_t buf_len) |
| Finds an executable inside the PATH entries. More... | |
| int | execve (const char *path, char *const argv[], char *const envp[]) |
Replaces the current process image with a new process image (argument vector), allows the caller to specify the environment of the executed program via envp. More... | |
| int | execv (const char *path, char *const argv[]) |
| Replaces the current process image with a new process image (argument vector). More... | |
| int | execvp (const char *file, char *const argv[]) |
| Replaces the current process image with a new process image (argument vector). More... | |
| int | execvpe (const char *file, char *const argv[], char *const envp[]) |
Replaces the current process image with a new process image (argument vector), allows the caller to specify the environment of the executed program via envp. More... | |
| int | execl (const char *path, const char *arg,...) |
| Replaces the current process image with a new process image (argument list). More... | |
| int | execlp (const char *file, const char *arg,...) |
| Replaces the current process image with a new process image (argument list). More... | |
| int | execle (const char *path, const char *arg,...) |
| Replaces the current process image with a new process image (argument list). More... | |
| int | execlpe (const char *file, const char *arg,...) |
| Replaces the current process image with a new process image (argument list). More... | |
Variables | |
| char ** | environ |
Reference to the environ variable in setenv.c. | |
|
inlinestatic |
Finds an executable inside the PATH entries.
| file | The file to search. |
| buf | The buffer where we will store the absolute path. |
| buf_len | The length of the buffer. |
| int execl | ( | const char * | path, |
| const char * | arg, | ||
| ... | |||
| ) |
Replaces the current process image with a new process image (argument list).
| path | The absolute path to the binary file to execute. |
| arg | A list of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| ... | The argument list. |
| int execle | ( | const char * | path, |
| const char * | arg, | ||
| ... | |||
| ) |
Replaces the current process image with a new process image (argument list).
| path | The absolute path to the binary file to execute. |
| arg | A list of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| ... | The argument list which contains as last argument the environment. |
| int execlp | ( | const char * | file, |
| const char * | arg, | ||
| ... | |||
| ) |
Replaces the current process image with a new process image (argument list).
| file | The name of the binary file to execute, which is searched inside the paths specified inside the PATH environmental variable. |
| arg | A list of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| ... | The argument list. |
| int execlpe | ( | const char * | file, |
| const char * | arg, | ||
| ... | |||
| ) |
Replaces the current process image with a new process image (argument list).
| file | The name of the binary file to execute, which is searched inside the paths specified inside the PATH environmental variable. |
| arg | A list of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| ... | The argument list which contains as last argument the environment. |
| int execv | ( | const char * | path, |
| char *const | argv[] | ||
| ) |
Replaces the current process image with a new process image (argument vector).
| path | The absolute path to the binary file to execute. |
| argv | A vector of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| int execve | ( | const char * | path, |
| char *const | argv[], | ||
| char *const | envp[] | ||
| ) |
Replaces the current process image with a new process image (argument vector), allows the caller to specify the environment of the executed program via envp.
| path | The absolute path to the binary file to execute. |
| argv | A vector of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| envp | A vector of one or more pointers to null-terminated strings that represent the environment list available to the executed program. |
| int execvp | ( | const char * | file, |
| char *const | argv[] | ||
| ) |
Replaces the current process image with a new process image (argument vector).
| file | The name of the binary file to execute, which is searched inside the paths specified inside the PATH environmental variable. |
| argv | A vector of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| int execvpe | ( | const char * | file, |
| char *const | argv[], | ||
| char *const | envp[] | ||
| ) |
Replaces the current process image with a new process image (argument vector), allows the caller to specify the environment of the executed program via envp.
| file | The name of the binary file to execute, which is searched inside the paths specified inside the PATH environmental variable. |
| argv | A vector of one or more pointers to null-terminated strings that represent the argument list available to the executed program. |
| envp | A vector of one or more pointers to null-terminated strings that represent the environment list available to the executed program. |