Correctly process some logical errors #211
1 changed files with 3 additions and 0 deletions
|
@ -228,6 +228,9 @@ func (t *FSTree) Put(prm common.PutPrm) (common.PutRes, error) {
|
||||||
p := t.treePath(prm.Address)
|
p := t.treePath(prm.Address)
|
||||||
|
|
||||||
if err := util.MkdirAllX(filepath.Dir(p), t.Permissions); err != nil {
|
if err := util.MkdirAllX(filepath.Dir(p), t.Permissions); err != nil {
|
||||||
|
if errors.Is(err, syscall.ENOSPC) {
|
||||||
|
return common.PutRes{}, common.ErrNoSpace
|
||||||
|
}
|
||||||
return common.PutRes{}, err
|
return common.PutRes{}, err
|
||||||
}
|
}
|
||||||
if !prm.DontCompress {
|
if !prm.DontCompress {
|
||||||
|
|
Loading…
Reference in a new issue