I call C++ function from C# project:
[System.Runtime.InteropServices.DllImport("C.dll")]
public static extern int FillSlist(out string slist);
and then
try
{
FillSlist(out slist);
}
catch
{
}
C++ dll is protected by third-party tool, so some code is being performed before FillSlist is really executed. Something really bad happens while this third-party code is executed and the program stops working at all. Neither "try" isolates the problem nor "AppDomain.CurrentDomain.UnhandledException" is executed.
Is there anything that can help to isolate crash of C++ function from C# calling code?