# Track open buffers when handling sync requests · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/a6ffcdd0cf2d82f5106dcf24ff94bd3532ed9519)

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

Visibility: public

Requested revision: a6ffcdd0cf2d82f5106dcf24ff94bd3532ed9519

Requested commit: a6ffcdd0cf2d82f5106dcf24ff94bd3532ed9519

Commit: a6ffcdd0cf2d82f5106dcf24ff94bd3532ed9519

Tree: f86a2ed93c20a858bdcd5cfa3d886f3cb86b5a10

Author: Nathan Sobo

Committer: Nathan Sobo

## Message

```
Track open buffers when handling sync requests

When a host sends a buffer to a guest for the first time, they record that
they have done so in a set tied to that guest's peer id. When the guest
reconnects and syncs buffers, they do so under a different peer id, so we
need to be sure we track which buffers we have sent them to avoid sending
them the same buffer twice, which violates the guest's assumptions.

```

## Parents

- [74843493f44d7ebcd32968483e77e180fd17334c](https://git.cafe/gitcafe/zed/commit/74843493f44d7ebcd32968483e77e180fd17334c?format=markdown)

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