additional error check

This commit is contained in:
2021-08-19 16:32:22 +03:00
parent f1566184cf
commit 34a4ebfeaa
2 changed files with 4 additions and 1 deletions

View File

@@ -52,6 +52,9 @@ func Flatten(rd io.ReadSeeker, w io.Writer) (_err error) {
if err == io.EOF {
break
}
if err != nil {
return err
}
if hdr.Typeflag != tar.TypeReg {
continue
}