mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Issue #20238: TarFile opened with external fileobj and "w:gz" mode didn't
write complete output on close.
This commit is contained in:
commit
7d68a1c921
3 changed files with 10 additions and 1 deletions
|
@ -1618,7 +1618,7 @@ class TarFile(object):
|
|||
if not extfileobj and fileobj is not None:
|
||||
fileobj.close()
|
||||
raise
|
||||
t._extfileobj = extfileobj
|
||||
t._extfileobj = False
|
||||
return t
|
||||
|
||||
@classmethod
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue