blob: 4e986fe2029e28984fc18dd5e8bf3d369e4012af (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
#include <stdio.h>
#include <err.h>
#include <unistd.h>
#include <fcntl.h>
/**
* NOTE: requires fdescfs to be mounted to run interpreted files (starting with #!)
*/
char *args[] = { "batchrun", NULL };
int
main()
{
//fcntl(3, F_SETFD, FD_CLOEXEC);
fexecve(3, args, NULL);
err(1, "fexecve()");
}
|