wineprefixcreate: Make sure the path returned by GetTempPath() during the $WINEPREFIX creation will be writable.

Alexandre Julliard julliard at winehq.org
Thu Sep 13 07:32:58 CDT 2007


Francois Gouget <fgouget at codeweavers.com> writes:

> mshtml.dll (and probably many others) use GetTempPath() during the 
> self-registration process. But at that point the Windows environment 
> variables, and in particular $TMP and $TEMP, have not been set yet, 
> especially not in the currently running process. So when mshtml.dll 
> calls GetTempPath(), that function returns the current directory, which 
> obviously is no good if that directory is not writable (like '/' for 
> instance). So this patch makes 'c:\windows\temp' the current directory, 
> which we know will be writable (and the chdir() should have no other 
> side effect in this script).

Actually GetTempPath is not supposed to use the current directory, I
committed a fix.

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list