[ATL] atlpath.h: This looked like a bug.

svn path=/trunk/; revision=72805
This commit is contained in:
Benedikt Freisen 2016-09-25 21:14:23 +00:00
parent ee95d592f0
commit 844f4e8868

View file

@ -181,10 +181,11 @@ public:
BOOL CompactPathEx(UINT nMaxChars, DWORD dwFlags = 0)
{
StringType result;
PXSTR str = result.GetBuffer(nMaxChars);
PathCompactPathExX(str, m_strPath, nMaxChars, dwFlags);
result.ReleaseBuffer();
StringType strTemp;
PXSTR str = strTemp.GetBuffer(nMaxChars);
BOOL result = PathCompactPathExX(str, m_strPath, nMaxChars, dwFlags);
strTemp.ReleaseBuffer();
m_strPath = strTemp;
return result;
}