Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <mach/mach.h>
- #include <stdio.h>
- int main(void) {
- mach_port_t kernel_task = 0;
- printf("task_for_pid: %d\n",host_get_special_port(mach_host_self(), HOST_LOCAL_NODE, 4, &kernel_task));
- if (!host_get_special_port(mach_host_self(), HOST_LOCAL_NODE, 4, &kernel_task)) return -1;
- return kernel_task;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement