CaptainJack
CaptainJack

Reputation: 1

.net application encountered error 0xc000142 when run on win2003 x64 sp2 enviroment

My .net application work well on x86,but when compiled x64 app,and run on win2003 x64 environment, it occurs the errors "the application failed to initialize properly(0xc0000142)" And my app has two part,main app named A.exe and the worker app B.exe!When run A program,It will launch nearly 100 B.exe through C# function Process.Start at one time! When i test my program on x86 system,all things go well,but on x64,nearly every time some of the B.exe process crashed with the error dialog contains 0xc0000142!

So I try to use process monitor tool to monitor B.exe's behavior, I found every time B.exe hanged after the operation LoadImage C:\Windows\System32\kernel32.exe,and this operation result is success! And if B.exe runs successfully,the next operation is RegOpenKey,and operated on (HKLM\System\CurrentControlSet\Control\Session Manager)! So,can anyone give me some useful tips or solution to help me solve this problem,thanx!

Upvotes: 0

Views: 747

Answers (1)

Yahia
Yahia

Reputation: 70369

0xc0000142 means STATUS_DLL_INIT_FAILED.

I suspect that process B uses some (3rd-party?) DLL(s) and one of those DLLs either has a problem with x64 and/or some dependency missing and/or some licensing issue and/or some permission/security issue.

With further details it might be possible to be more specific...

Upvotes: 1

Related Questions