2008/10/2 Aric Stewart <aric(a)codeweavers.com>:
@@ -543,34 +543,50 @@ DWORD WINAPI VerInstallFileW( len = WideCharToMultiByte( CP_ACP, 0, srcfilename, -1, NULL, 0, NULL, NULL ); if ((wsrcf = HeapAlloc( GetProcessHeap(), 0, len ))) WideCharToMultiByte( CP_ACP, 0, srcfilename, -1, wsrcf, len, NULL, NULL ); + else + ret = VIF_OUTOFMEMORY; } - if (srcdir) + if (srcdir && !ret)
Remove the extra space here.
+ static const CHAR szSrcDir[] = "C:\\windows\\temp"; + static const CHAR szDestDir[] = "C:\\windows\\temp\\test"; + static const CHAR szCurDir[] = "C:\\";
This isn't exactly what I meant. C:\Windows might not even exist on NT4/Win2000 and the temp directory might not be in %WINDIR%\temp. You should use GetTempPath instead. (Hard-coding C:\ is also something to be avoided if at all possible.) -- Rob Shearman