builder/vmware: correct logic in cehcking if file is still there

pull/667/merge
Mitchell Hashimoto 13 years ago
parent b12871dc28
commit ea09c1105c

@ -50,7 +50,7 @@ func (stepCleanFiles) Run(state multistep.StateBag) multistep.StepAction {
ui.Message(fmt.Sprintf("Deleting: %s", path))
if err = dir.Remove(path); err != nil {
// Only report the error if the file still exists
if _, serr := os.Stat(path); serr == nil || os.IsNotExist(serr) {
if _, serr := os.Stat(path); serr == nil || !os.IsNotExist(serr) {
state.Put("error", err)
return multistep.ActionHalt
}

Loading…
Cancel
Save