[Mono-bugs] [Bug 676095] New: ConstructorInfo cannot be serialized

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Mar 1 17:50:51 EST 2011


https://bugzilla.novell.com/show_bug.cgi?id=676095

https://bugzilla.novell.com/show_bug.cgi?id=676095#c0


           Summary: ConstructorInfo cannot be serialized
    Classification: Mono
           Product: Mono: Class Libraries
           Version: 2.10.x
          Platform: All
        OS/Version: Windows 7
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: CORLIB
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: tobias.bohnen at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---


Created an attachment (id=416933)
 --> (http://bugzilla.novell.com/attachment.cgi?id=416933)
test case

User-Agent:       Mozilla/5.0 (Windows; Windows NT 6.1) AppleWebKit/534.23
(KHTML, like Gecko) Chrome/11.0.686.0 Safari/534.23

Trying to serialize a ConstructorInfo results in the following exception.

Unhandled Exception: System.Runtime.Serialization.SerializationException: Type
S
ystem.Reflection.MonoCMethod is not marked as Serializable.
  at
System.Runtime.Serialization.Formatters.Binary.BinaryCommon.CheckSerializab
le (System.Type type, ISurrogateSelector selector, StreamingContext context)
[0x
00000] in <filename unknown>:0
  at System.Runtime.Serialization.Formatters.Binary.ObjectWriter.GetObjectData
(
System.Object obj, System.Runtime.Serialization.Formatters.Binary.TypeMetadata&
metadata, System.Object& data) [0x00000] in <filename unknown>:0
  at System.Runtime.Serialization.Formatters.Binary.ObjectWriter.WriteObject
(Sy
stem.IO.BinaryWriter writer, Int64 id, System.Object obj) [0x00000] in
<filename
 unknown>:0
  at
System.Runtime.Serialization.Formatters.Binary.ObjectWriter.WriteObjectInst
ance (System.IO.BinaryWriter writer, System.Object obj, Boolean isValueObject)
[
0x00000] in <filename unknown>:0
  at
System.Runtime.Serialization.Formatters.Binary.ObjectWriter.WriteQueuedObje
cts (System.IO.BinaryWriter writer) [0x00000] in <filename unknown>:0
  at
System.Runtime.Serialization.Formatters.Binary.ObjectWriter.WriteObjectGrap
h (System.IO.BinaryWriter writer, System.Object obj,
System.Runtime.Remoting.Mes
saging.Header[] headers) [0x00000] in <filename unknown>:0
  at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Serialize
(S
ystem.IO.Stream serializationStream, System.Object graph,
System.Runtime.Remotin
g.Messaging.Header[] headers) [0x00000] in <filename unknown>:0
  at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Serialize
(S
ystem.IO.Stream serializationStream, System.Object graph) [0x00000] in
<filename
 unknown>:0
  at test.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0

Reproducible: Always

-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the mono-bugs mailing list