Browse Source

Merge pull request #642 from whynotAC/master

fix leveldb mount bug
pull/645/head
Chris Lu 7 years ago
committed by GitHub
parent
commit
63c4884b16
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      weed/storage/disk_location.go

3
weed/storage/disk_location.go

@ -164,10 +164,11 @@ func (l *DiskLocation) UnloadVolume(vid VolumeId) error {
l.Lock() l.Lock()
defer l.Unlock() defer l.Unlock()
_, ok := l.volumes[vid]
v, ok := l.volumes[vid]
if !ok { if !ok {
return fmt.Errorf("Volume not loaded, VolumeId: %d", vid) return fmt.Errorf("Volume not loaded, VolumeId: %d", vid)
} }
v.Close()
delete(l.volumes, vid) delete(l.volumes, vid)
return nil return nil
} }

Loading…
Cancel
Save