summaryrefslogtreecommitdiffstats
path: root/Source/kwsys/SystemTools.cxx
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2005-04-07 21:20:33 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2005-04-07 21:20:33 (GMT)
commit3387db4c053db0c8ff78f8db4f22a2b00d0aa35d (patch)
treeac5b125cdf7611e5d29c6a4ee206daf4bd73bcf3 /Source/kwsys/SystemTools.cxx
parentbe32b258cb621d3845f4d33931adca8826f1c5b3 (diff)
downloadCMake-3387db4c053db0c8ff78f8db4f22a2b00d0aa35d.zip
CMake-3387db4c053db0c8ff78f8db4f22a2b00d0aa35d.tar.gz
CMake-3387db4c053db0c8ff78f8db4f22a2b00d0aa35d.tar.bz2
BUG: if short path or long path fails return the original input
Diffstat (limited to 'Source/kwsys/SystemTools.cxx')
-rw-r--r--Source/kwsys/SystemTools.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/kwsys/SystemTools.cxx b/Source/kwsys/SystemTools.cxx
index 7e925f1..0e42684 100644
--- a/Source/kwsys/SystemTools.cxx
+++ b/Source/kwsys/SystemTools.cxx
@@ -2244,13 +2244,13 @@ kwsys_stl::string SystemTools::GetActualCaseForPath(const char* p)
std::string path;
if(!SystemTools::GetShortPath(p, path))
{
- return path;
+ return p;
}
char buffer[MAX_PATH+1];
int len = ::GetLongPathName(path.c_str(), buffer, MAX_PATH+1);
if(len == 0 || len > MAX_PATH+1)
{
- return path;
+ return p;
}
return buffer;
#endif