Wednesday, 2 June 2010

.NET: LoaderLock was detected

Error Message
Attempting managed execution inside OS Loader lock. Do not attempt to run managed code inside a DllMain or image initialization function since doing so can cause the application to hang.


The problem can be solved by switching off the MDA:

Debug -> Exceptions -> Managed Debug Assistants

and unchecking the LoaderLock item.

This simply tells visual studio that you do not wish to be alerted by this exception everytime you debug the application.

No comments: