diff options
Diffstat (limited to 'cpp/src/IcePatch2/ClientUtil.cpp')
-rwxr-xr-x | cpp/src/IcePatch2/ClientUtil.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/cpp/src/IcePatch2/ClientUtil.cpp b/cpp/src/IcePatch2/ClientUtil.cpp index 9670736406a..d24669c72c8 100755 --- a/cpp/src/IcePatch2/ClientUtil.cpp +++ b/cpp/src/IcePatch2/ClientUtil.cpp @@ -156,12 +156,14 @@ IcePatch2::Patcher::Patcher(const CommunicatorPtr& communicator, const PatcherFe const_cast<Int&>(_chunkSize) = 1; } - if(_dataDir[0] != '/') - { #ifdef _WIN32 + if(_dataDir[0] != '/' && !(_dataDir.size() > 1 && isalpha(_dataDir[0]) && _dataDir[1] == ':')) + { char cwd[_MAX_PATH]; if(_getcwd(cwd, _MAX_PATH) == NULL) #else + if(_dataDir[0] != '/') + { char cwd[PATH_MAX]; if(getcwd(cwd, PATH_MAX) == NULL) #endif |