]>
Commit | Line | Data |
---|---|---|
d9a64523 A |
1 | #include <mach/mach_init.h> |
2 | #include <mach/mach_vm.h> | |
3 | #include <stdlib.h> | |
4 | ||
0a7de745 A |
5 | int |
6 | main(void) | |
d9a64523 A |
7 | { |
8 | kern_return_t kr; | |
9 | mach_vm_address_t addr = 50ULL * 1024ULL * 1024ULL * 1024ULL; | |
10 | ||
11 | kr = mach_vm_allocate(current_task(), &addr, 4096, VM_FLAGS_FIXED); | |
12 | ||
13 | if (kr == KERN_SUCCESS) { | |
14 | return 0; | |
15 | } else { | |
16 | return 1; | |
17 | } | |
18 | } |