Gitiles
Code Review
Sign In
gerrit-public.fairphone.software
/
platform
/
external
/
valgrind
/
e15728c1b152b8f325183c4de9837b8a1ada00ff
/
.
/
memcheck
/
tests
/
mmaptest.c
blob: 74a21ed2601349d24f58481341a459fdc749ae21 [
file
] [
log
] [
blame
]
#include
<sys/types.h>
#include
<sys/stat.h>
#include
<fcntl.h>
#include
<unistd.h>
#include
<sys/mman.h>
int
main
()
{
int
fd
;
mkdir
(
"dir"
,
0777
);
fd
=
open
(
"dir"
,
O_RDONLY
);
mmap
(
NULL
,
4711
,
PROT_READ
,
MAP_PRIVATE
,
fd
,
0
);
return
0
;
}