fix for launching unix executables

Rein Klazes rklazes at xs4all.nl
Fri Jun 4 08:25:00 CDT 2004


Hi,

Changelog:
	dlls/kernel	: process.c
	Fix a crash when launching Unix executables.

Rein.
-- 
Rein Klazes
rklazes at xs4all.nl
-------------- next part --------------
--- wine/dlls/kernel/process.c	2004-06-03 12:30:34.000000000 +0200
+++ mywine/dlls/kernel/process.c	2004-06-04 15:18:37.000000000 +0200
@@ -1279,7 +1279,8 @@
         char **envptr = envp;
 
         /* first the extra strings */
-        for (p = extra_env; *p; p += strlen(p) + 1) *envptr++ = alloc_env_string( "", p );
+        if( extra_env)
+            for (p = extra_env; *p; p += strlen(p) + 1) *envptr++ = alloc_env_string( "", p );
         /* then put PATH, TEMP, TMP, HOME and WINEPREFIX from the unix env */
         if ((p = getenv("PATH"))) *envptr++ = alloc_env_string( "PATH=", p );
         if ((p = getenv("TEMP"))) *envptr++ = alloc_env_string( "TEMP=", p );


More information about the wine-patches mailing list