From 85225751a77918a6efd6f89028615ecb3305da14 Mon Sep 17 00:00:00 2001 From: Brad Warren Date: Thu, 30 Apr 2020 13:45:47 -0700 Subject: [PATCH] Revert "Temporary fix, REVERT" This reverts commit 0976176a5692cd5c76020f7bed025b4785302263. --- .../certbot_apache/_internal/apache_util.py | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/certbot-apache/certbot_apache/_internal/apache_util.py b/certbot-apache/certbot_apache/_internal/apache_util.py index c0e57c3f5..fde812478 100644 --- a/certbot-apache/certbot_apache/_internal/apache_util.py +++ b/certbot-apache/certbot_apache/_internal/apache_util.py @@ -19,9 +19,6 @@ from certbot import util from certbot.compat import os -# TEMPORARY WORKAROUND -import os as stdlib_os - logger = logging.getLogger(__name__) @@ -79,19 +76,9 @@ def safe_copy(source, target): copied or the target file hash does not match with the source file. """ - orig_perms = None - try: - orig_perms = stdlib_os.stat(target) - except OSError: - # target file was not found - pass - for _ in range(3): try: shutil.copy2(source, target) - if orig_perms: - stdlib_os.chown(target, orig_perms.st_uid) - stdlib_os.chmod(target, oct(orig_perms.st_mode & 0o777)) except IOError as e: emsg = "Could not copy {} to {}: {}".format( source, target, e