1
0
Fork 0
mirror of https://github.com/chrislusf/seaweedfs synced 2024-09-11 11:30:32 +02:00

avoid invalid memory address or nil pointer dereference

This commit is contained in:
Konstantin Lebedev 2022-04-18 12:10:22 +05:00
parent 9ae66f55fc
commit 9438738693

View file

@ -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
}