mscoree: Invoke installed win32 mono runtime or exec mono native for .NET executables (try 3)

Paul Chitescu paulc at voip.null.ro
Mon Oct 9 15:19:18 CDT 2006


On Mon, 9 Oct 2006, Hans Leidekker wrote:
> On Monday 09 October 2006 18:28, Paul Chitescu wrote:
> 
> +    /* set current directory so we can find mono's DLLs */
> +    chdir(buf1);
> 
> I think you are calling Unix chdir on a Windows path here. Also,
> buf1 is hardly a descriptive name and statically allocating 256
> bytes for a path is asking for trouble.
> 
> Note that instead of changing the working directory you could
> also add the Mono bin dir to the search path:
> 
> lstrcpyA(new_path, old_path);
> lstrcatA(new_path, ";");
> lstrcatA(new_path, mono_path);
> 
> if (!SetEnvironmentVariableA("PATH", new_path))
>     return -1;
> 
>  -Hans

Thanks!

In the end I figured out the problem with chdir() - worked for me because 
I had a properly installed Gtk2 library.

I prefer to keep stack usage low - Wine is already hungry about stack 
space. Oh, yes, I increased the buffers to MAX_PATH.

Paul



More information about the wine-patches mailing list