mirror of
https://github.com/containers/skopeo.git
synced 2025-08-31 14:20:21 +00:00
Merge pull request #1965 from mtrmac/verify-error
Fix error handling of signature.NewEphemeralGPGSigningMechanism
This commit is contained in:
@@ -116,11 +116,15 @@ func (opts *standaloneVerifyOptions) run(args []string, stdout io.Writer) error
|
||||
return fmt.Errorf("Error reading public keys from %s: %w", opts.publicKeyFile, err)
|
||||
}
|
||||
mech, publicKeyfingerprints, err = signature.NewEphemeralGPGSigningMechanism(publicKeys)
|
||||
if err != nil {
|
||||
return fmt.Errorf("Error initializing GPG: %w", err)
|
||||
|
||||
}
|
||||
} else {
|
||||
mech, err = signature.NewGPGSigningMechanism()
|
||||
}
|
||||
if err != nil {
|
||||
return fmt.Errorf("Error initializing GPG: %w", err)
|
||||
if err != nil {
|
||||
return fmt.Errorf("Error initializing GPG: %w", err)
|
||||
}
|
||||
}
|
||||
defer mech.Close()
|
||||
|
||||
|
Reference in New Issue
Block a user