Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
go-dms3
Commits
6f140d25
Unverified
Commit
6f140d25
authored
Jul 18, 2018
by
Whyrusleeping
Committed by
GitHub
Jul 18, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #5258 from ipfs/fix/5247
when sending blocks in bitswap, close streams asynchronously
parents
256ad270
3e306586
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
exchange/bitswap/network/ipfs_impl.go
exchange/bitswap/network/ipfs_impl.go
+4
-3
No files found.
exchange/bitswap/network/ipfs_impl.go
View file @
6f140d25
...
...
@@ -123,9 +123,10 @@ func (bsnet *impl) SendMessage(
s
.
Reset
()
return
err
}
// Yes, return this error. We have no reason to believe that the block
// was actually *sent* unless we see the EOF.
return
inet
.
FullClose
(
s
)
// TODO(https://github.com/libp2p/go-libp2p-net/issues/28): Avoid this goroutine.
go
inet
.
AwaitEOF
(
s
)
return
s
.
Close
()
}
func
(
bsnet
*
impl
)
SetDelegate
(
r
Receiver
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment