Help! Debugger reporting System.IO.FIleLoadException.

  • Thread starter Thread starter Ken Varn
  • Start date Start date
K

Ken Varn

I am trying to remote debug a C# application but the debugger is reporting
the following exception:

An unhandled exception of type 'System.IO.FileLoadException' occurred in
Unknown Module.
Additional information: Unverifiable assembly 'FrameGrabber' failed policy
check.

The FrameGrabber assembly is a C++ managed DLL.

I cannot get a stack trace on the exception in the debugger.
I have seen this occur when a C++ managed DLL cannot locate an unmanaged
library
dependency.

The weird thing is that I do not get this exception when I run my
application without the debugger.

I have used the "Depends" tool to check the DLL and found no missing DLLs.
Can someone help me out on what I can
do to locate the cause of this exception?

--
-----------------------------------
Ken Varn
Senior Software Engineer
Diebold Inc.
(e-mail address removed)
-----------------------------------
 
Your explanation makes sense, however the twist is that I able to remotely
debug my managed C++ application that uses the same DLL and it does not
produce this exception. What's with that?



--
-----------------------------------
Ken Varn
Senior Software Engineer
Diebold Inc.
(e-mail address removed)
-----------------------------------
 
Hi Ken,

Sorry, but I know absolutely nothing about managed C++ and how permissions
work in that environment. Are you doing that remote debugging in the same
way, i.e. by launching the remote app from within Visual Studio? Or are you
launching it directly on the remote pc and attaching a debugger, in which
case the permissions issue doesn't apply?

Regards,

Mark
--
Author of "Comprehensive VB .NET Debugging"
http://www.apress.com/book/bookDisplay.html?bID=128


Your explanation makes sense, however the twist is that I able to remotely
debug my managed C++ application that uses the same DLL and it does not
produce this exception. What's with that?



--
-----------------------------------
Ken Varn
Senior Software Engineer
Diebold Inc.
(e-mail address removed)
-----------------------------------
 
I tried to run CASPOL and disabled all .NET security and that seemed to fix
the problem. It seems strange however that the security is so tight for C#,
but not for C++. I have had a whole slew of issues regarding remote
debugging. A lot of other security restrictions are a big pain and I wish
there was an option to bypass all of them with some sort of registry setting
or something.

--
-----------------------------------
Ken Varn
Senior Software Engineer
Diebold Inc.
(e-mail address removed)
-----------------------------------
Mark Pearce said:
Hi Ken,

Sorry, but I know absolutely nothing about managed C++ and how permissions
work in that environment. Are you doing that remote debugging in the same
way, i.e. by launching the remote app from within Visual Studio? Or are you
launching it directly on the remote pc and attaching a debugger, in which
case the permissions issue doesn't apply?

Regards,

Mark
--
Author of "Comprehensive VB .NET Debugging"
http://www.apress.com/book/bookDisplay.html?bID=128


Your explanation makes sense, however the twist is that I able to remotely
debug my managed C++ application that uses the same DLL and it does not
produce this exception. What's with that?



--
-----------------------------------
Ken Varn
Senior Software Engineer
Diebold Inc.
(e-mail address removed)
-----------------------------------
 
Back
Top