Check return value from volume.SetVolumeOwnership() in downwardAPI

The function can fail, so we must check the return code.
This commit is contained in:
Rodrigo Campos 2016-08-07 13:10:05 -03:00 committed by Paul Morie
parent 568f4c2e63
commit 5637569f74

View File

@ -187,7 +187,11 @@ func (b *downwardAPIVolumeMounter) SetUpAt(dir string, fsGroup *int64) error {
return err return err
} }
volume.SetVolumeOwnership(b, fsGroup) err = volume.SetVolumeOwnership(b, fsGroup)
if err != nil {
glog.Errorf("Error applying volume ownership settings for group: %v", fsGroup)
return err
}
return nil return nil
} }