diff options
author | Martin Poirier <theeth@yahoo.com> | 2011-01-28 03:45:53 +0300 |
---|---|---|
committer | Martin Poirier <theeth@yahoo.com> | 2011-01-28 03:45:53 +0300 |
commit | 0b6c13093741e7bddd0968eaa8e7e518f90f55ba (patch) | |
tree | d27ed8aa0f964a3f96b500bb7d20463cadd51cf6 /release/scripts/io | |
parent | 185f77438567412f0d1061fa973696ee1edb9e2b (diff) |
[#25783] Network rendering fails with windows paths
Potential fix. Absolute windows path weren't detected as absolute on linux.
Diffstat (limited to 'release/scripts/io')
-rw-r--r-- | release/scripts/io/netrender/utils.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/release/scripts/io/netrender/utils.py b/release/scripts/io/netrender/utils.py index 065f3c72ed5..8cdb0230379 100644 --- a/release/scripts/io/netrender/utils.py +++ b/release/scripts/io/netrender/utils.py @@ -202,7 +202,10 @@ def hashData(data): def prefixPath(prefix_directory, file_path, prefix_path, force = False): - if os.path.isabs(file_path): + if (os.path.isabs(file_path) or + len(file_path) >= 3 and (file_path[1:3] == ":/" or file_path[1:3] == ":\\") or # Windows absolute path don't count as absolute on unix, have to handle them myself + file_path[0] == "/" or file_path[0] == "\\"): # and vice versa + # if an absolute path, make sure path exists, if it doesn't, use relative local path full_path = file_path if force or not os.path.exists(full_path): |