Add Marshal.GetExceptionPointers (#11125)
authorYi Zhang (CLR) <yizhang82@users.noreply.github.com>
Fri, 21 Apr 2017 09:01:40 +0000 (02:01 -0700)
committerJan Vorlicek <janvorli@microsoft.com>
Fri, 21 Apr 2017 09:01:40 +0000 (02:01 -0700)
* Add Marshal.GetExceptionPointers

* Remove SecurityCritical

src/mscorlib/src/System/Runtime/InteropServices/Marshal.cs
src/vm/ecalllist.h

index 248e0d5..6fb6311 100644 (file)
@@ -824,6 +824,9 @@ namespace System.Runtime.InteropServices
         }
 
         [MethodImplAttribute(MethodImplOptions.InternalCall)]
+        public static extern /* struct _EXCEPTION_POINTERS* */ IntPtr GetExceptionPointers();
+        
+        [MethodImplAttribute(MethodImplOptions.InternalCall)]
         public static extern int GetExceptionCode();
 
 
index 6ed29b8..5c3e5f8 100644 (file)
@@ -946,6 +946,7 @@ FCFuncStart(gInteropMarshalFuncs)
     FCFuncElement("DestroyStructure", MarshalNative::DestroyStructure)
     FCFuncElement("UnsafeAddrOfPinnedArrayElement", MarshalNative::FCUnsafeAddrOfPinnedArrayElement)
     FCFuncElement("GetExceptionCode", ExceptionNative::GetExceptionCode)
+    FCFuncElement("GetExceptionPointers", ExceptionNative::GetExceptionPointers)
     QCFuncElement("GetHINSTANCE", COMModule::GetHINSTANCE)
 
     FCFuncElement("OffsetOfHelper", MarshalNative::OffsetOfHelper)