source:
EcnlProtoTool/trunk/musl-1.1.18/src/process/fexecve.c
Last change on this file was 444, checked in by , 4 years ago | |
---|---|
|
|
File size: 272 bytes |
Rev | Line | |
---|---|---|
[444] | 1 | #include <unistd.h> |
2 | #include <errno.h> | |
3 | ||
4 | void __procfdname(char *, unsigned); | |
5 | ||
6 | int fexecve(int fd, char *const argv[], char *const envp[]) | |
7 | { | |
8 | char buf[15 + 3*sizeof(int)]; | |
9 | __procfdname(buf, fd); | |
10 | execve(buf, argv, envp); | |
11 | if (errno == ENOENT) errno = EBADF; | |
12 | return -1; | |
13 | } |
Note:
See TracBrowser
for help on using the repository browser.