[Mono-dev] Re: [WIN32] NtQueryInformationProcess patch help needed

Robert Jordan robertj at gmx.net
Sat Apr 15 07:22:37 EDT 2006


Hi Kornél,

How about using LoadLibrary/GetProcAddress in this case?
It's ugly but it would fix the issue.

Robert

> The cucrrent code in SVN uses GetProcessId that requires Windows XP SP1 
> or Windows Server 2003 or later. Mono supports Windows 2000 or later.
> 
> In addition checking for GetProcessId (HAVE_GETPROCESSID) is useless 
> because Windows header files contain the latest API and availability of 
> GetProcessId depends on _WIN32_WINNT not the actual operating system.
> 
> Furthermore we have a single Windows binary so we should use a single 
> source code for Windows.
> 
> The attached patch uses NtQueryInformationProcess that solves all the 
> above problems.
> 
> My only problem is that some libc functions were linked from ntdll that 
> caused mono to crash sometimes. Then I tried to link to msvcrt before 
> ntdll but the crashes remained. For some unknown reason no mono-1.dll is 
> crated and libmono is linked statically to mono.exe when applying this 
> patch.
> 
> Please help me solving the problem.
> 
> Kornél
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list




More information about the Mono-devel-list mailing list