>Robert Jordan wrote: >> Jonathan Gagnon wrote: >>> Lately, I started using the OnDeserialized event to do some stuff >>> after an object is deserialized. It works fine when I compile it on >>> my machine, unfortunately, when compiled on our build machine, I get >>> the following error when deserializing my object with mono : >>> >>> System.NotSupportedException: Collection is read-only >>> at System.Array.InternalArray__RemoveAt[Object] (Int32 index) >>> [0x00000] in >>> /tmp/scratch/BUILD/mono-1.2.3.1/mcs/class/corlib/System/Array.cs:131 >> >> OnDeserialized was not supported in 1.2.3.1. Please update to the >> latest Mono 1.2.5.1.
>Sorry, it is actually implemented since Mono 1.2. >>> System.NotSupportedException: Collection is read-only >>> at System.Array.InternalArray__RemoveAt[Object] (Int32 index) >>> [0x00000] in >>> /tmp/scratch/BUILD/mono-1.2.3.1/mcs/class/corlib/System/Array.cs:131 >>> at (wrapper managed-to-managed) >>> Croesus.EntityManagement.IAccessControlInformation[]:System.Collectio >>> ns.Gene >>> ric.IList`1.RemoveAt (int) >This seems to be a problem in you own callback code. Nevertheless, please try the latest Mono 1.2.5.1 that fixes a lot of problems with >generics. If it's still failing, please file a bug with a test case at http://www.mono-project.com/Bugs. I tried with Mono 1.2.5.1 and I still have the same problem. It is unlikely to be related to my own callback code since it is not even called (at least, it is not in the callstack). The delegate calls something that isn't marked with the OnDeserialized attribute, making me think that the in-memory pointer is corrupted. I will try to come up with a simple test case, although up to now, every simple case that I tried work just fine. Jonathan _______________________________________________ Mono-list maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-list
