bpo-35981: apply os.path.abspath only to basedir (for windows)

This commit is contained in:
Bruno P. Kinoshita 2019-12-02 16:05:38 +13:00
parent 2fe4c48917
commit a865e8d071
1 changed files with 2 additions and 1 deletions

View File

@ -1027,7 +1027,8 @@ def make_archive(base_name, format, root_dir=None, base_dir=None, verbose=0,
if root_dir is not None:
if logger is not None:
logger.debug("changing into '%s'", root_dir)
base_name = os.path.abspath(base_name)
base_dir, base_file = os.path.split(base_name)
base_name = os.path.join(os.path.abspath(base_dir), base_file)
if not dry_run:
os.chdir(root_dir)