mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
Merge pull request #2931 from kmlebedev/fix_nil_dataBackend
avoid invalid memory address or nil pointer dereference
This commit is contained in:
commit
97c6e0efb1
|
@ -260,7 +260,7 @@ func (v *Volume) collectStatus() (maxFileKey types.NeedleId, datFileSize int64,
|
|||
defer v.dataFileAccessLock.RUnlock()
|
||||
glog.V(3).Infof("collectStatus volume %d", v.Id)
|
||||
|
||||
if v.nm == nil {
|
||||
if v.nm == nil || v.DataBackend == nil {
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue