mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-05-02 20:27:49 +08:00
fix nil volume data backend
fix https://github.com/seaweedfs/seaweedfs/issues/5417
This commit is contained in:
parent
9ca871af53
commit
aed6fdffd2
@ -236,6 +236,9 @@ func (vs *VolumeServer) VolumeStatus(ctx context.Context, req *volume_server_pb.
|
||||
if v == nil {
|
||||
return nil, fmt.Errorf("not found volume id %d", req.VolumeId)
|
||||
}
|
||||
if v.DataBackend == nil {
|
||||
return nil, fmt.Errorf("volume %d data backend not found", req.VolumeId)
|
||||
}
|
||||
|
||||
volumeSize, _, _ := v.DataBackend.GetStat()
|
||||
resp.IsReadOnly = v.IsReadOnly()
|
||||
|
Loading…
Reference in New Issue
Block a user