mirror of https://github.com/containers/podman.git
Allow image errors to bubble up from lower level functions.
Currently we ignore ErrMultipleImages being returned from findImageInRepoTags. Fixes: https://github.com/containers/podman/issues/8868 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
parent
f261bfc549
commit
d0093026a2
|
@ -497,7 +497,7 @@ func (ir *Runtime) getLocalImage(inputName string) (string, *storage.Image, erro
|
||||||
return inputName, repoImage, nil
|
return inputName, repoImage, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
return "", nil, errors.Wrapf(ErrNoSuchImage, err.Error())
|
return "", nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
// ID returns the image ID as a string
|
// ID returns the image ID as a string
|
||||||
|
|
|
@ -45,7 +45,8 @@ func findImageInRepotags(search imageParts, images []*Image) (*storage.Image, er
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if len(candidates) == 0 {
|
if len(candidates) == 0 {
|
||||||
return nil, errors.Errorf("unable to find a name and tag match for %s in repotags", searchName)
|
|
||||||
|
return nil, errors.Wrapf(define.ErrNoSuchImage, "unable to find a name and tag match for %s in repotags", searchName)
|
||||||
}
|
}
|
||||||
|
|
||||||
// If more then one candidate and the candidates all have same name
|
// If more then one candidate and the candidates all have same name
|
||||||
|
|
Loading…
Reference in New Issue