mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-18 01:43:47 +00:00
swarm/fuse: lock around minfo (#393)
This commit is contained in:
parent
a715a46bf6
commit
5f33e9a8f2
1 changed files with 2 additions and 0 deletions
|
|
@ -100,6 +100,7 @@ func mountDir(t *testing.T, api *api.Api, files map[string]fileInfo, bzzHash str
|
|||
found := false
|
||||
mi := swarmfs.Listmounts()
|
||||
for _, minfo := range mi {
|
||||
minfo.lock.RLock()
|
||||
if minfo.MountPoint == mountDir {
|
||||
if minfo.StartManifest != bzzHash ||
|
||||
minfo.LatestManifest != bzzHash ||
|
||||
|
|
@ -108,6 +109,7 @@ func mountDir(t *testing.T, api *api.Api, files map[string]fileInfo, bzzHash str
|
|||
}
|
||||
found = true
|
||||
}
|
||||
minfo.lock.RUnlock()
|
||||
}
|
||||
|
||||
// Test listMounts
|
||||
|
|
|
|||
Loading…
Reference in a new issue