+2009-09-09 Sebastien Pouliot <sebastien@ximian.com>
+
+ * SecurityManager.cs, SecurityManager_2_1.cs: Replace existing
+ throw methods (for coreclr) with a single one.
+
2009-05-02 Sebastien Pouliot <sebastien@ximian.com>
* CodeAccessPermission.cs (ThrowSecurityException): Don't include
throw new SecurityException (message, an, granted, refused, method, SecurityAction.InheritanceDemand, null, null, null);
}
- private static void FieldAccessException (IntPtr caller, IntPtr field)
- {
- throw new FieldAccessException (Locale.GetText ("Field access not allowed."));
- }
+ // called by the runtime when CoreCLR is enabled
- private static void MethodAccessException (IntPtr caller, IntPtr callee)
+ private static void ThrowException (Exception ex)
{
- throw new MethodAccessException (Locale.GetText ("Method call not allowed."));
+ throw ex;
}
// internal - get called by the class loader
// called by the runtime when CoreCLR is enabled
- private static void FieldAccessException (IntPtr caller, IntPtr field)
+ private static void ThrowException (Exception ex)
{
- throw new FieldAccessException (Locale.GetText ("Field access not allowed."));
- }
-
- private static void MethodAccessException (IntPtr caller, IntPtr callee)
- {
- throw new MethodAccessException (Locale.GetText ("Method call not allowed."));
+ throw ex;
}
// internal - get called by the class loader