Skip to content

Commit

Permalink
pass true instead of false to set_maximum
Browse files Browse the repository at this point in the history
  • Loading branch information
koekeishiya committed Nov 23, 2020
1 parent 75bca43 commit b6b495c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/osax/mach_loader.c
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ bool mach_loader_inject_payload(pid_t pid)
return false;
}

if (vm_protect(task, stack, stack_size, 0, VM_PROT_READ | VM_PROT_WRITE) != KERN_SUCCESS) {
if (vm_protect(task, stack, stack_size, 1, VM_PROT_READ | VM_PROT_WRITE) != KERN_SUCCESS) {
fprintf(stderr, "could not change protection for stack segment\n");
return false;
}
Expand Down

0 comments on commit b6b495c

Please sign in to comment.