diff options
author | Timo Furrer <tuxtimo@gmail.com> | 2019-01-17 14:15:53 (GMT) |
---|---|---|
committer | Berker Peksag <berker.peksag@gmail.com> | 2019-01-17 14:15:53 (GMT) |
commit | 17f05bbc78dbcd1db308266c31370da9ec1b1d47 (patch) | |
tree | 27fd4f29df7b62bdad0400bd151fcf1d1d3d9689 /Lib/uu.py | |
parent | f1d8e7cf17a010d2657822e06a41b30c9542a8c7 (diff) | |
download | cpython-17f05bbc78dbcd1db308266c31370da9ec1b1d47.zip cpython-17f05bbc78dbcd1db308266c31370da9ec1b1d47.tar.gz cpython-17f05bbc78dbcd1db308266c31370da9ec1b1d47.tar.bz2 |
bpo-33687: Fix call to os.chmod() in uu.decode() (GH-7282)
Diffstat (limited to 'Lib/uu.py')
-rwxr-xr-x | Lib/uu.py | 5 |
1 files changed, 1 insertions, 4 deletions
@@ -133,10 +133,7 @@ def decode(in_file, out_file=None, mode=None, quiet=False): out_file = sys.stdout.buffer elif isinstance(out_file, str): fp = open(out_file, 'wb') - try: - os.path.chmod(out_file, mode) - except AttributeError: - pass + os.chmod(out_file, mode) out_file = fp opened_files.append(out_file) # |