diff options
author | William Chargin <wchargin@gmail.com> | 2020-02-12 19:56:02 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-12 19:56:02 (GMT) |
commit | 674935b8caf33e47c78f1b8e197b1b77a04992d2 (patch) | |
tree | fc7f81510ae2bdf298f3fc8dd2c3d2b7584ebc18 /Misc | |
parent | 4fac7ed43ebf1771a8fe86fdfe7b9991f3be78cd (diff) | |
download | cpython-674935b8caf33e47c78f1b8e197b1b77a04992d2.zip cpython-674935b8caf33e47c78f1b8e197b1b77a04992d2.tar.gz cpython-674935b8caf33e47c78f1b8e197b1b77a04992d2.tar.bz2 |
bpo-18819: tarfile: only set device fields for device files (GH-18080)
The GNU docs describe the `devmajor` and `devminor` fields of the tar
header struct only in the context of character and block special files,
suggesting that in other cases they are not populated. Typical utilities
behave accordingly; this patch teaches `tarfile` to do the same.
Diffstat (limited to 'Misc')
-rw-r--r-- | Misc/ACKS | 1 | ||||
-rw-r--r-- | Misc/NEWS.d/next/Library/2020-01-20-10-06-19.bpo-18819.H4qsoS.rst | 3 |
2 files changed, 4 insertions, 0 deletions
@@ -286,6 +286,7 @@ Brad Chapman Greg Chapman Mitch Chapman Matt Chaput +William Chargin Yogesh Chaudhari David Chaum Nicolas Chauvat diff --git a/Misc/NEWS.d/next/Library/2020-01-20-10-06-19.bpo-18819.H4qsoS.rst b/Misc/NEWS.d/next/Library/2020-01-20-10-06-19.bpo-18819.H4qsoS.rst new file mode 100644 index 0000000..e9f111a --- /dev/null +++ b/Misc/NEWS.d/next/Library/2020-01-20-10-06-19.bpo-18819.H4qsoS.rst @@ -0,0 +1,3 @@ +Omit ``devmajor`` and ``devminor`` fields for non-device files in +:mod:`tarfile` archives, enabling bit-for-bit compatibility with GNU +``tar(1)``. |