mirror of
https://github.com/containers/podman.git
synced 2025-11-30 01:58:46 +08:00
Merge pull request #27566 from grey3228/fix/check_newGenericDecompressor_err
check err returned by newGenericDecompressor
This commit is contained in:
@@ -10,6 +10,9 @@ type uncompressedDecompressor struct {
|
|||||||
|
|
||||||
func newUncompressedDecompressor(compressedFilePath string) (*uncompressedDecompressor, error) {
|
func newUncompressedDecompressor(compressedFilePath string) (*uncompressedDecompressor, error) {
|
||||||
d, err := newGenericDecompressor(compressedFilePath)
|
d, err := newGenericDecompressor(compressedFilePath)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
return &uncompressedDecompressor{*d}, err
|
return &uncompressedDecompressor{*d}, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ type zipDecompressor struct {
|
|||||||
|
|
||||||
func newZipDecompressor(compressedFilePath string) (*zipDecompressor, error) {
|
func newZipDecompressor(compressedFilePath string) (*zipDecompressor, error) {
|
||||||
d, err := newGenericDecompressor(compressedFilePath)
|
d, err := newGenericDecompressor(compressedFilePath)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
return &zipDecompressor{*d, nil, nil}, err
|
return &zipDecompressor{*d, nil, nil}, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user