# Fix SIGSEGV handler for AArch64 Darwin targets · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/c4237e890945468c4efc4fdb0f5f3f17fac25046)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: c4237e890945468c4efc4fdb0f5f3f17fac25046

Requested commit: c4237e890945468c4efc4fdb0f5f3f17fac25046

Commit: c4237e890945468c4efc4fdb0f5f3f17fac25046

Tree: f2eda190af54296b88c554f5aa455d8ac921099f

Author: Cezary Kupaj

Committer: Alex Rønne Petersen

## Message

```
Fix SIGSEGV handler for AArch64 Darwin targets

* ucontext_t ptr is 8-byte aligned instead of 16-byte aligned which @alignCast() expects
* Retrieve pc address from ucontext_t since unwind_state is null
* Work around __mcontext_data being written incorrectly by the kernel
```

## Parents

- [0cb9ffc6d87cafdb676d59e5d06192cc438058a3](https://git.cafe/gitcafe/zig/commit/0cb9ffc6d87cafdb676d59e5d06192cc438058a3?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/c4237e890945468c4efc4fdb0f5f3f17fac25046?format=markdown)
