[Mono-bugs] [Bug 49476][Nor] New - When System.Type is in a read-only prop, it can be xml serialized
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Wed, 8 Oct 2003 23:19:15 -0400 (EDT)
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by bmaurer@users.sf.net.
http://bugzilla.ximian.com/show_bug.cgi?id=49476
--- shadow/49476 2003-10-08 23:19:15.000000000 -0400
+++ shadow/49476.tmp.30107 2003-10-08 23:19:15.000000000 -0400
@@ -0,0 +1,42 @@
+Bug#: 49476
+Product: Mono/MCS
+Version: unspecified
+OS:
+OS Details:
+Status: NEW
+Resolution:
+Severity: Unknown
+Priority: Normal
+Component: Misc
+AssignedTo: lluis@ximian.com
+ReportedBy: bmaurer@users.sf.net
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: When System.Type is in a read-only prop, it can be xml serialized
+
+Description of Problem:
+MS has what looks like a bug that allows the following code to execute
+
+using System;
+using System.Xml;
+using System.Xml.Serialization;
+
+public class T {
+ static void Main () {
+ XmlSerializer s = new XmlSerializer (typeof (T));
+ }
+ public Type t { get { return null; }}
+}
+
+Actual Results:
+Unhandled Exception: System.InvalidOperationException: Assembly cannot be
+serialized because it does not have a default public constructor
+in [0x00041] (at
+/devel/mcs/class/System.XML/System.Xml.Serialization/ReflectionHelper.cs:58)
+System.Xml.Serialization.ReflectionHelper:CheckSerializableType (System.Type)
+
+
+Expected Results:
+Successful execution