diff options
author | Nitzo <nitzo2001@yahoo.com> | 2016-01-11 21:19:21 +0100 |
---|---|---|
committer | Nitzo <nitzo2001@yahoo.com> | 2016-01-11 21:19:21 +0100 |
commit | 06c46d7d09f13ce1e7d68621e8e43365fd1007d6 (patch) | |
tree | 720d75575d10dea06992111a968baf324782b992 | |
parent | [HotFolder] fix #2279 (diff) | |
download | pyload-06c46d7d09f13ce1e7d68621e8e43365fd1007d6.tar.xz |
fix #2284 (thanks @youlJunior)
-rw-r--r-- | module/plugins/internal/Hoster.py | 4 | ||||
-rw-r--r-- | module/plugins/internal/misc.py | 7 |
2 files changed, 4 insertions, 7 deletions
diff --git a/module/plugins/internal/Hoster.py b/module/plugins/internal/Hoster.py index 69610e8a0..b0391b471 100644 --- a/module/plugins/internal/Hoster.py +++ b/module/plugins/internal/Hoster.py @@ -34,7 +34,7 @@ if not hasattr(__builtin__.property, "setter"): class Hoster(Base): __name__ = "Hoster" __type__ = "hoster" - __version__ = "0.54" + __version__ = "0.55" __status__ = "stable" __pattern__ = r'^unmatchable$' @@ -279,7 +279,7 @@ class Hoster(Base): self.pyfile.setStatus("downloading") - dl_folder = os.path.abspath(self.pyload.config.get('general', 'download_folder')) + dl_folder = self.pyload.config.get('general', 'download_folder') dl_dirname = safejoin(dl_folder, self.pyfile.package().folder) dl_filename = safejoin(dl_dirname, dl_basename) diff --git a/module/plugins/internal/misc.py b/module/plugins/internal/misc.py index df5814ca6..43ddf2752 100644 --- a/module/plugins/internal/misc.py +++ b/module/plugins/internal/misc.py @@ -38,7 +38,7 @@ except ImportError: class misc(object): __name__ = "misc" __type__ = "plugin" - __version__ = "0.21" + __version__ = "0.22" __status__ = "stable" __pattern__ = r'^unmatchable$' @@ -475,12 +475,9 @@ def truncate(name, length): def safepath(value): """ Remove invalid characters and truncate the path if needed - - @NOTE: Returns absolute path """ - value = os.path.abspath(value) drive, filename = os.path.splitdrive(value) - filename = os.path.join(os.sep, *map(safename, filename.split(os.sep))) + filename = os.path.join(os.sep if os.path.isabs(filename) else "", *map(safename, filename.split(os.sep))) path = drive + filename try: |