Author: spouliot
Date: 2005-03-31 08:47:55 -0500 (Thu, 31 Mar 2005)
New Revision: 42426
Modified:
trunk/mcs/class/corlib/System/ChangeLog
trunk/mcs/class/corlib/System/Exception.cs
Log:
2005-03-31 Sebastien Pouliot <[EMAIL PROTECTED]>
* Exception.cs: Added Assert for TypeInformation to GetObjectData and
ToString methods (not required for 2.0 as TypeInformation will be
deprecated). Added null check for GetObjectData.
Modified: trunk/mcs/class/corlib/System/ChangeLog
===================================================================
--- trunk/mcs/class/corlib/System/ChangeLog 2005-03-31 13:47:38 UTC (rev
42425)
+++ trunk/mcs/class/corlib/System/ChangeLog 2005-03-31 13:47:55 UTC (rev
42426)
@@ -1,4 +1,9 @@
+2005-03-31 Sebastien Pouliot <[EMAIL PROTECTED]>
+ * Exception.cs: Added Assert for TypeInformation to GetObjectData and
+ ToString methods (not required for 2.0 as TypeInformation will be
+ deprecated). Added null check for GetObjectData.
+
Tue Mar 29 11:47:19 CEST 2005 Paolo Molaro <[EMAIL PROTECTED]>
* Delegate.cs: allow IronPython 0.7 to compile.
Modified: trunk/mcs/class/corlib/System/Exception.cs
===================================================================
--- trunk/mcs/class/corlib/System/Exception.cs 2005-03-31 13:47:38 UTC (rev
42425)
+++ trunk/mcs/class/corlib/System/Exception.cs 2005-03-31 13:47:55 UTC (rev
42426)
@@ -236,11 +236,17 @@
return this;
}
+#if ONLY_1_1
+ [ReflectionPermission (SecurityAction.Assert, TypeInformation =
true)]
+#endif
public virtual void GetObjectData (SerializationInfo info,
StreamingContext context)
{
+ if (info == null)
+ throw new ArgumentNullException ("info");
+
if (class_name == null)
class_name = GetType ().FullName;
-
+
info.AddValue ("ClassName", class_name);
info.AddValue ("Message", message);
info.AddValue ("InnerException", inner_exception);
@@ -253,6 +259,9 @@
info.AddValue ("ExceptionMethod", null);
}
+#if ONLY_1_1
+ [ReflectionPermission (SecurityAction.Assert, TypeInformation =
true)]
+#endif
public override string ToString ()
{
System.Text.StringBuilder result = new
System.Text.StringBuilder (this.GetType ().FullName);
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches