mirror of
https://github.com/ipfs/kubo.git
synced 2026-03-10 18:57:57 +08:00
Buffer response channel to prevent deadlock
License: MIT Signed-off-by: Jeromy <jeromyj@gmail.com>
This commit is contained in:
parent
40533eda5e
commit
332891f7b2
@ -119,7 +119,7 @@ type interestReq struct {
|
||||
// block we received) this function will not be called, as the cid will likely
|
||||
// still be in the interest cache.
|
||||
func (s *Session) isLiveWant(c *cid.Cid) bool {
|
||||
resp := make(chan bool)
|
||||
resp := make(chan bool, 1)
|
||||
s.interestReqs <- interestReq{
|
||||
c: c,
|
||||
resp: resp,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user