LoaderLock Exception when running Fetchers on Dev Box (1 Viewer)

ChubbyArse

Portal Member
December 28, 2011
40
1
Hi, I thought I'd document my solution to a exception that gettsing thrown by DirectX when testing my code that calls the IMDBFetcher on my Dev Box.

The exception states:

LoaderLock occurred
Message: Managed Debugging Assistant 'LoaderLock' has detected a problem in 'D:\Work\EpgMovieGuide\trunk\ConfigurationTestHarness\bin\Debug\ConfigurationTestHarness.vshost.exe'.
Additional information: DLL 'C:\Windows\assembly\GAC\Microsoft.DirectX.Direct3D\1.0.2902.0__31bf3856ad364e35\Microsoft.DirectX.Direct3D.dll' is 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 exception detail has only: "The name '$exception' does not exist in the current context"

In order to get past this exception when testing locally, Go to the debug menu, then pick exceptions, and then expand Managed Debugging Assistants, and uncheck throw for LoaderLock.

Taken from here.

Hopefully other newbies find this useful.
 

Users who are viewing this thread

Top Bottom