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-pinner
Commits
f08a8a14
Commit
f08a8a14
authored
5 years ago
by
Steven Allen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: don't hold the pin lock while updating pins
fixes
https://github.com/ipfs/go-ipfs/issues/6885
parent
495dd3cb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
pin.go
pin.go
+4
-0
No files found.
pin.go
View file @
f08a8a14
...
...
@@ -526,7 +526,11 @@ func (p *pinner) Update(ctx context.Context, from, to cid.Cid, unpin bool) error
return
fmt
.
Errorf
(
"'from' cid was not recursively pinned already"
)
}
// Temporarily unlock while we fetch the differences.
p
.
lock
.
Unlock
()
err
:=
dagutils
.
DiffEnumerate
(
ctx
,
p
.
dserv
,
from
,
to
)
p
.
lock
.
Lock
()
if
err
!=
nil
{
return
err
}
...
...
This diff is collapsed.
Click to expand it.
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