# Eventloop: Fix deadlock in linux event loop implementation · gitcafe/zig

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

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

Visibility: public

Requested revision: 0eed7ec9d51fe8c0dd22b72da0130ad9d31877d0

Requested commit: 0eed7ec9d51fe8c0dd22b72da0130ad9d31877d0

Commit: 0eed7ec9d51fe8c0dd22b72da0130ad9d31877d0

Tree: edabf258c98ede7cb8d06cfae73e3e9142ac0a48

Author: Timon Kruiper

Committer: Timon Kruiper

## Message

```
Eventloop: Fix deadlock in linux event loop implementation

A simple empty main with evented-io would not quit, because some
threads were still waiting to be resumed (by the os). The os.write to
the eventfd only wakes up one thread and thus there are multiple writes
needed to wake up all the other threads.

```

## Parents

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

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