Sign in
llvm
/
llvm-project
/
41d59a36459ea99ada4819a26072366f77484f87
/
.
/
compiler-rt
/
test
/
sanitizer_common
/
TestCases
/
Posix
/
mmap_test.c
blob: 3c272f95a015c2d9d74989056af9a9921a492cc8 [
file
] [
log
] [
blame
]
// RUN: %clang %s -o %t && %run %t
#include
<assert.h>
#include
<sys/mman.h>
int
main
()
{
char
*
buf
=
(
char
*)
mmap
(
0
,
100000
,
PROT_READ
|
PROT_WRITE
,
MAP_PRIVATE
|
MAP_ANONYMOUS
,
-
1
,
0
);
assert
(
buf
);
munmap
(
buf
,
100000
);
}