diff --git a/imgextractor.py b/imgextractor.py index 48dbcb7..bd81aec 100644 --- a/imgextractor.py +++ b/imgextractor.py @@ -136,6 +136,8 @@ def scan_dir(root_inode, root_path=""): cap = ' capabilities={cap}'.format(cap=cap) if entry_inode.is_dir: dir_target = self.EXTRACT_DIR + entry_inode_path.replace(' ', '_').replace('"', '') + if dir_target.endswith('.') and os.name == 'nt': + dir_target = dir_target[:-1] if not os.path.isdir(dir_target): os.makedirs(dir_target) if os.name == 'posix' and os.geteuid() == 0: