repo.or.cz
/
valgrind.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Add missing zstd.h to coregrind Makefile.am noinst_HEADERS
[valgrind.git]
/
memcheck
/
tests
/
linux
/
check_execveat.c
blob
ad6107fb106bc4856e15ff8ef68c688c070b7b09
1
#include <sys/syscall.h>
2
#include <errno.h>
3
#include <unistd.h>
4
#include <stddef.h>
5
6
int
main
(
int
argc
,
char
**
argv
)
7
{
8
int
has_execveat
=
0
;
9
#if defined(__NR_execveat)
10
errno
=
0
;
11
syscall
(
__NR_execveat
,
0
,
NULL
,
0
,
0
,
0
);
12
has_execveat
= (
errno
!=
ENOSYS
);
13
#else
14
has_execveat
=
0
;
15
#endif
16
17
return
has_execveat
?
0
:
1
;
18
}