fix the mode of tarfile.open

fixes: #2641
This commit is contained in:
Yu Ming Zhu 2021-02-03 10:04:38 +00:00
parent 0c4db061d4
commit 8b9aa559c8

View file

@ -4939,7 +4939,7 @@ def _get_tarball_list(archive_id, tarpath):
result = []
if not os.path.exists(tarpath):
return result
with tarfile.open(tarpath, 'rb') as archive:
with tarfile.open(tarpath, 'r') as archive:
for entry in archive:
filename = koji.fixEncoding(entry.name)
result.append({'archive_id': archive_id,