From ea7207963c8477c0d2b128ee877f4fa37730a207 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 15 Feb 2005 21:59:46 +0000 Subject: [PATCH] pending exception assertion makeover git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6949 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Lib/csharp/csharphead.swg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/csharp/csharphead.swg b/Lib/csharp/csharphead.swg index 8302b4959..bf98d9ae1 100644 --- a/Lib/csharp/csharphead.swg +++ b/Lib/csharp/csharphead.swg @@ -139,8 +139,8 @@ DllExport void SWIGSTDCALL SWIGRegisterExceptionCallbacks_$module(SWIG_CSharpExc } public static void Set(Exception e) { - if (pendingException != null) - throw new Exception("Throwing exceptions from unmanaged code has gone broken down"); + if (pendingException != null) // Checks for missing pending exception code + throw new Exception("FATAL: An earlier pending exception from unmanaged code was missed and thus not thrown (" + pendingException.ToString() + ")", e); // unmanaged code destructors may not be called pendingException = e; lock(typeof($modulePINVOKE)) { numExceptionsPending++;