common: collect dropped error

This commit is contained in:
Lars Lehtonen 2019-10-23 09:34:32 -07:00 committed by Megan Marsh
parent 8d8bd3f891
commit 731e0332cf
1 changed files with 4 additions and 0 deletions

View File

@ -162,6 +162,10 @@ func (c *ISOConfig) Prepare(ctx *interpolate.Context) (warnings []string, errs [
}
if c.ISOChecksumType == "file" {
u, err := url.Parse(c.ISOUrls[0])
if err != nil {
errs = append(errs, fmt.Errorf("error parsing URL <%s>: %s",
c.ISOUrls[0], err))
}
wd, err := os.Getwd()
if err != nil {
log.Printf("get working directory: %v", err)