mirror of
https://github.com/ocrmypdf/OCRmyPDF.git
synced 2026-05-16 10:35:49 -04:00
Remove code that attempted to manage xattrs out of output file
Feature requested in issue #1179, but caused #1195. On further review, there is no platform independent way to manage extended attributes and it is not clear copying them through is necessarily the sensible thing to do. Closes #1179.
This commit is contained in:
@@ -992,10 +992,3 @@ def copy_final(
|
||||
# get the appropriate umask, ownership, etc.
|
||||
with open(output_file, 'w+b') as output_stream:
|
||||
copyfileobj(input_stream, output_stream)
|
||||
# Attempt to copy file attributes from input to output
|
||||
if original_file:
|
||||
with suppress(OSError):
|
||||
# Copy original file's permissions, ownership, etc. if possible
|
||||
copystat(original_file, output_file)
|
||||
# Set output file's modification time to now
|
||||
Path(output_file).touch(exist_ok=True)
|
||||
|
||||
Reference in New Issue
Block a user