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-bitswap
Commits
bb99f55b
Commit
bb99f55b
authored
Mar 09, 2015
by
Jeromy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add warning comment about possibly leaked goroutines
parent
8de772f4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
bitswap.go
bitswap.go
+6
-0
No files found.
bitswap.go
View file @
bb99f55b
...
@@ -260,6 +260,9 @@ loop:
...
@@ -260,6 +260,9 @@ loop:
select
{
select
{
case
<-
done
:
case
<-
done
:
case
<-
ctx
.
Done
()
:
case
<-
ctx
.
Done
()
:
// NB: we may be abandoning goroutines here before they complete
// this shouldnt be an issue because they will complete soon anyways
// we just don't want their being slow to impact bitswap transfer speeds
}
}
return
nil
return
nil
}
}
...
@@ -412,6 +415,9 @@ func (bs *Bitswap) wantNewBlocks(ctx context.Context, bkeys []u.Key) {
...
@@ -412,6 +415,9 @@ func (bs *Bitswap) wantNewBlocks(ctx context.Context, bkeys []u.Key) {
select
{
select
{
case
<-
done
:
case
<-
done
:
case
<-
ctx
.
Done
()
:
case
<-
ctx
.
Done
()
:
// NB: we may be abandoning goroutines here before they complete
// this shouldnt be an issue because they will complete soon anyways
// we just don't want their being slow to impact bitswap transfer speeds
}
}
}
}
...
...
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