]> Sergey Matveev's repositories - btrtrc.git/commit
Fix write error handling
authorMatt Joiner <anacrolix@gmail.com>
Sun, 25 Dec 2022 08:23:07 +0000 (19:23 +1100)
committerMatt Joiner <anacrolix@gmail.com>
Sun, 25 Dec 2022 08:24:16 +0000 (19:24 +1100)
commitfed765b2a058a5c3b2dc8905edd07638cbcfe3a5
tree00017c729ed2533c7d51e993d67fee98c39d5178
parent48ad1a8aca56922aca5d15632c58894985a71a69
Fix write error handling

Fixes https://github.com/anacrolix/torrent/issues/798.

Prior to this fix, it looks like the writer would just keep writing chunks of the front buffer (incorrectly if there was an error), until presumably the writer would be killed by read hangup elsewhere.
peer-conn-msg-writer.go
tests/issue-798/main.go [new file with mode: 0644]